diff --git a/backend/collaboration-service/consumer.js b/backend/collaboration-service/consumer.js
new file mode 100644
index 0000000000..16d9ca83bd
--- /dev/null
+++ b/backend/collaboration-service/consumer.js
@@ -0,0 +1,139 @@
+const { Mistral } = require('@mistralai/mistralai');
+
+const amqp = require('amqplib/callback_api');
+const { sendWsMessage, broadcastToRoom } = require('./ws');
+const axios = require('axios');
+const dotenv = require('dotenv');
+dotenv.config();
+
+const CLOUDAMQP_URL = process.env.CLOUDAMQP_URL;
+const COLLAB_SERVICE_URL = "http://localhost:8003";
+
+function arrayEquals(a, b) {
+ return Array.isArray(a) &&
+ Array.isArray(b) &&
+ a.length === b.length &&
+ a.every((val, index) => val === b[index]);
+}
+
+function checkSubset(parentArray, subsetArray) {
+ return subsetArray.every((el) => {
+ return parentArray.includes(el)
+ });
+}
+
+// In-memory store to track unmatched users
+let unmatchedUsers = [];
+
+// Function to set up RabbitMQ consumer
+const setupConsumer = () => {
+ amqp.connect(CLOUDAMQP_URL, (err, conn) => {
+ if (err) {
+ console.error('Connection error in consumer.js:', err);
+ return;
+ }
+
+ conn.createChannel((err, ch) => {
+ if (err) throw err;
+ const queue = 'collab_queue';
+ ch.assertQueue(queue, { durable: false });
+
+ console.log('Listening for messages in RabbitMQ queue for collab...');
+ ch.consume(queue, async (msg) => {
+ const userRequest = JSON.parse(msg.content.toString());
+ console.log('Received user request:', userRequest);
+ console.log('User request type:', userRequest.type);
+ if (userRequest.status === 'cancel') {
+ // Handle cancel request
+ const userIndex = unmatchedUsers.findIndex(u => u.userId === userRequest.userId);
+ if (userIndex !== -1) {
+ console.log(`Cancelling request for user ${userRequest.userId}`);
+ clearTimeout(unmatchedUsers[userIndex].timeoutId); // Clear any pending timeout
+ unmatchedUsers.splice(userIndex, 1); // Remove user from unmatched list
+ sendWsMessage(userRequest.userId, { status: 'CANCELLED' });
+ console.log(`Cancelled matching request for user ${userRequest.userId}`);
+ } else {
+ console.log(`No unmatched request found for user ${userRequest.userId}`);
+ }
+ sendWsMessage(userRequest.userId, { status: 'CANCELLED' });
+ console.log(`Cancelled matching request for user ${userRequest.userId}`);
+ } else if (userRequest.type === 'ASK_COPILOT') {
+ // Function to make the API call with retry logic
+
+ try {
+ const apiKey = process.env.MISTRAL_API_KEY;
+ const client = new Mistral({ apiKey: apiKey });
+ prompt = userRequest.prompt;
+ currentCode = userRequest.code;
+
+ const chatResponse = await client.chat.complete({
+ model: 'mistral-large-latest',
+ messages: [{role: 'user', content: currentCode + '\n' + prompt}],
+ });
+ console.log('Asking Copilot:', chatResponse);
+
+ broadcastToRoom(userRequest.roomId, { type: 'ASK_COPILOT', response: chatResponse.choices[0].message.content });
+ } catch (error) {
+ console.error("Failed to fetch chat response:", error);
+ broadcastToRoom(userRequest.roomId, { type: 'ASK_COPILOT', response: "Error fetching response from assistant." });
+ }
+ }
+ else {
+ // Handle match request
+ const match = unmatchedUsers.find(u =>
+ checkSubset(u.category, userRequest.category) ||
+ checkSubset(userRequest.category, u.category)
+ ) || unmatchedUsers.find(u => u.difficulty === userRequest.difficulty);
+
+ if (match) {
+ try {
+ console.log(`Matched user ${userRequest.userId} with user ${match.userId}`);
+
+ // Create room in collaboration service
+ const response = await axios.post(`${COLLAB_SERVICE_URL}/rooms/create`, {
+ users: [userRequest.userId, match.userId],
+ difficulty: userRequest.difficulty,
+ category: userRequest.category
+ });
+ console.log(response.data);
+ const { roomId } = response.data;
+
+ // Notify both users
+ [userRequest, match].forEach(user => {
+ sendWsMessage(user.userId, {
+ status: 'MATCH_FOUND',
+ roomId,
+ matchedUserId: user === userRequest ? match.userId : userRequest.userId,
+ difficulty: userRequest.difficulty,
+ category: userRequest.category
+ });
+ });
+
+ // Clear the timeouts for both users
+ clearTimeout(match.timeoutId);
+
+ // Remove matched user from unmatchedUsers
+ unmatchedUsers = unmatchedUsers.filter(u => u.userId !== match.userId);
+ } catch (error) {
+ console.error('Error creating room:', error);
+ }
+ } else {
+ // Set a timeout to remove unmatched users after 30 seconds
+ const timeoutId = setTimeout(() => {
+ unmatchedUsers = unmatchedUsers.filter(u => u.userId !== userRequest.userId);
+ sendWsMessage(userRequest.userId, { status: 'timeout' });
+ }, 30000); // 30 seconds timeout
+
+ // Add the new user with their timeout ID
+ unmatchedUsers.push({ ...userRequest, timeoutId });
+ }
+ }
+
+ ch.ack(msg); // Acknowledge message processing
+ });
+ });
+ });
+};
+
+
+module.exports = { setupConsumer };
diff --git a/backend/collaboration-service/controllers/copilotControllers.js b/backend/collaboration-service/controllers/copilotControllers.js
new file mode 100644
index 0000000000..29f862dd8c
--- /dev/null
+++ b/backend/collaboration-service/controllers/copilotControllers.js
@@ -0,0 +1,16 @@
+const { sendToQueue } = require("../../collaboration-service/mq");
+
+const askCopilot = async (req, res) => {
+
+ const { code, prompt, type, roomId } = req.body;
+ console.log(`Received request to ask Copilot for prompt: ${prompt}`);
+
+ sendToQueue({ code, prompt, type, roomId });
+
+ res.status(200).send({ status: 'Request received. Waiting for Copilot response.' });
+
+};
+
+module.exports = {
+ askCopilot,
+};
\ No newline at end of file
diff --git a/backend/collaboration-service/index.js b/backend/collaboration-service/index.js
index 266c9b41d7..0e14454414 100644
--- a/backend/collaboration-service/index.js
+++ b/backend/collaboration-service/index.js
@@ -1,7 +1,13 @@
+const dotenv = require('dotenv');
+dotenv.config();
const express = require('express');
const cors = require('cors');
const { setupWebSocket } = require('./ws');
const roomRoutes = require('./routes/room');
+const { setupConsumer } = require('./consumer');
+require('dotenv').config();
+const amqp = require('amqplib/callback_api');
+
const app = express();
const PORT = process.env.PORT || 8003;
@@ -17,3 +23,7 @@ const server = app.listen(PORT, () => {
app.use('/rooms', roomRoutes);
setupWebSocket(server);
+
+setupConsumer();
+
+
diff --git a/backend/collaboration-service/mq.js b/backend/collaboration-service/mq.js
new file mode 100644
index 0000000000..886a139075
--- /dev/null
+++ b/backend/collaboration-service/mq.js
@@ -0,0 +1,33 @@
+const amqp = require('amqplib/callback_api');
+const dotenv = require('dotenv');
+dotenv.config();
+
+const CLOUDAMQP_URL = process.env.CLOUDAMQP_URL;
+
+let channel;
+
+// Establish connection to RabbitMQ and create a channel
+amqp.connect(CLOUDAMQP_URL, (err, conn) => {
+ if (err) throw err;
+
+ conn.createChannel((err, ch) => {
+ if (err) throw err;
+ channel = ch;
+ const queue = 'collab_queue';
+ ch.assertQueue(queue, { durable: false });
+ console.log('RabbitMQ connected, queue asserted:', queue);
+ });
+});
+
+// Function to send messages to the queue
+const sendToQueue = (message) => {
+ const queue = 'collab_queue';
+ if (!channel) {
+ console.error('RabbitMQ channel not initialised');
+ return;
+ }
+ channel.sendToQueue(queue, Buffer.from(JSON.stringify(message)));
+ console.log('Sent message to RabbitMQ for collab:', message);
+};
+
+module.exports = { sendToQueue };
diff --git a/backend/collaboration-service/package-lock.json b/backend/collaboration-service/package-lock.json
index 0fdf945a21..a5a919c15b 100644
--- a/backend/collaboration-service/package-lock.json
+++ b/backend/collaboration-service/package-lock.json
@@ -9,17 +9,68 @@
"version": "1.0.0",
"license": "ISC",
"dependencies": {
+ "@mistralai/mistralai": "^1.1.0",
+ "amqplib": "^0.10.4",
+ "axios": "^1.7.7",
"cors": "^2.8.5",
"dotenv": "^16.4.5",
"express": "^4.21.1",
"http": "^0.0.1-security",
"uuid": "^10.0.0",
- "ws": "^8.18.0"
+ "ws": "^8.18.0",
+ "zod": "^3.23.8"
},
"devDependencies": {
"nodemon": "^3.1.7"
}
},
+ "node_modules/@acuminous/bitsyntax": {
+ "version": "0.1.2",
+ "resolved": "https://registry.npmjs.org/@acuminous/bitsyntax/-/bitsyntax-0.1.2.tgz",
+ "integrity": "sha512-29lUK80d1muEQqiUsSo+3A0yP6CdspgC95EnKBMi22Xlwt79i/En4Vr67+cXhU+cZjbti3TgGGC5wy1stIywVQ==",
+ "dependencies": {
+ "buffer-more-ints": "~1.0.0",
+ "debug": "^4.3.4",
+ "safe-buffer": "~5.1.2"
+ },
+ "engines": {
+ "node": ">=0.8"
+ }
+ },
+ "node_modules/@acuminous/bitsyntax/node_modules/debug": {
+ "version": "4.3.7",
+ "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.7.tgz",
+ "integrity": "sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==",
+ "dependencies": {
+ "ms": "^2.1.3"
+ },
+ "engines": {
+ "node": ">=6.0"
+ },
+ "peerDependenciesMeta": {
+ "supports-color": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/@acuminous/bitsyntax/node_modules/ms": {
+ "version": "2.1.3",
+ "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz",
+ "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA=="
+ },
+ "node_modules/@acuminous/bitsyntax/node_modules/safe-buffer": {
+ "version": "5.1.2",
+ "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
+ "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
+ },
+ "node_modules/@mistralai/mistralai": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/@mistralai/mistralai/-/mistralai-1.1.0.tgz",
+ "integrity": "sha512-YueaIX+g4+QTX6ERLjZLZMOhlC0/EoqwpayWrUKfTM9EGTyiOPdxFLpLpg5B9PsaxOrmZDC88pOp4QgSMqVr8w==",
+ "peerDependencies": {
+ "zod": ">= 3"
+ }
+ },
"node_modules/accepts": {
"version": "1.3.8",
"resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz",
@@ -33,6 +84,20 @@
"node": ">= 0.6"
}
},
+ "node_modules/amqplib": {
+ "version": "0.10.4",
+ "resolved": "https://registry.npmjs.org/amqplib/-/amqplib-0.10.4.tgz",
+ "integrity": "sha512-DMZ4eCEjAVdX1II2TfIUpJhfKAuoCeDIo/YyETbfAqehHTXxxs7WOOd+N1Xxr4cKhx12y23zk8/os98FxlZHrw==",
+ "dependencies": {
+ "@acuminous/bitsyntax": "^0.1.2",
+ "buffer-more-ints": "~1.0.0",
+ "readable-stream": "1.x >=1.1.9",
+ "url-parse": "~1.5.10"
+ },
+ "engines": {
+ "node": ">=10"
+ }
+ },
"node_modules/anymatch": {
"version": "3.1.3",
"resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz",
@@ -53,6 +118,21 @@
"integrity": "sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==",
"license": "MIT"
},
+ "node_modules/asynckit": {
+ "version": "0.4.0",
+ "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
+ "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q=="
+ },
+ "node_modules/axios": {
+ "version": "1.7.7",
+ "resolved": "https://registry.npmjs.org/axios/-/axios-1.7.7.tgz",
+ "integrity": "sha512-S4kL7XrjgBmvdGut0sN3yJxqYzrDOnivkBiN0OFs6hLiUam3UPvswUo0kqGyhqUZGEOytHyumEdXsAkgCOUf3Q==",
+ "dependencies": {
+ "follow-redirects": "^1.15.6",
+ "form-data": "^4.0.0",
+ "proxy-from-env": "^1.1.0"
+ }
+ },
"node_modules/balanced-match": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz",
@@ -121,6 +201,11 @@
"node": ">=8"
}
},
+ "node_modules/buffer-more-ints": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/buffer-more-ints/-/buffer-more-ints-1.0.0.tgz",
+ "integrity": "sha512-EMetuGFz5SLsT0QTnXzINh4Ksr+oo4i+UGTXEshiGCQWnsgSs7ZhJ8fzlwQ+OzEMs0MpDAMr1hxnblp5a4vcHg=="
+ },
"node_modules/bytes": {
"version": "3.1.2",
"resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz",
@@ -174,6 +259,17 @@
"fsevents": "~2.3.2"
}
},
+ "node_modules/combined-stream": {
+ "version": "1.0.8",
+ "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
+ "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
+ "dependencies": {
+ "delayed-stream": "~1.0.0"
+ },
+ "engines": {
+ "node": ">= 0.8"
+ }
+ },
"node_modules/concat-map": {
"version": "0.0.1",
"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
@@ -217,6 +313,11 @@
"integrity": "sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==",
"license": "MIT"
},
+ "node_modules/core-util-is": {
+ "version": "1.0.3",
+ "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz",
+ "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ=="
+ },
"node_modules/cors": {
"version": "2.8.5",
"resolved": "https://registry.npmjs.org/cors/-/cors-2.8.5.tgz",
@@ -256,6 +357,14 @@
"url": "https://github.com/sponsors/ljharb"
}
},
+ "node_modules/delayed-stream": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
+ "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==",
+ "engines": {
+ "node": ">=0.4.0"
+ }
+ },
"node_modules/depd": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz",
@@ -411,6 +520,38 @@
"node": ">= 0.8"
}
},
+ "node_modules/follow-redirects": {
+ "version": "1.15.9",
+ "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.9.tgz",
+ "integrity": "sha512-gew4GsXizNgdoRyqmyfMHyAmXsZDk6mHkSxZFCzW9gwlbtOW44CDtYavM+y+72qD/Vq2l550kMF52DT8fOLJqQ==",
+ "funding": [
+ {
+ "type": "individual",
+ "url": "https://github.com/sponsors/RubenVerborgh"
+ }
+ ],
+ "engines": {
+ "node": ">=4.0"
+ },
+ "peerDependenciesMeta": {
+ "debug": {
+ "optional": true
+ }
+ }
+ },
+ "node_modules/form-data": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.1.tgz",
+ "integrity": "sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw==",
+ "dependencies": {
+ "asynckit": "^0.4.0",
+ "combined-stream": "^1.0.8",
+ "mime-types": "^2.1.12"
+ },
+ "engines": {
+ "node": ">= 6"
+ }
+ },
"node_modules/forwarded": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz",
@@ -656,6 +797,11 @@
"node": ">=0.12.0"
}
},
+ "node_modules/isarray": {
+ "version": "0.0.1",
+ "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
+ "integrity": "sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ=="
+ },
"node_modules/media-typer": {
"version": "0.3.0",
"resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz",
@@ -882,6 +1028,11 @@
"node": ">= 0.10"
}
},
+ "node_modules/proxy-from-env": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-1.1.0.tgz",
+ "integrity": "sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg=="
+ },
"node_modules/pstree.remy": {
"version": "1.1.8",
"resolved": "https://registry.npmjs.org/pstree.remy/-/pstree.remy-1.1.8.tgz",
@@ -904,6 +1055,11 @@
"url": "https://github.com/sponsors/ljharb"
}
},
+ "node_modules/querystringify": {
+ "version": "2.2.0",
+ "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz",
+ "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ=="
+ },
"node_modules/range-parser": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz",
@@ -928,6 +1084,17 @@
"node": ">= 0.8"
}
},
+ "node_modules/readable-stream": {
+ "version": "1.1.14",
+ "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.14.tgz",
+ "integrity": "sha512-+MeVjFf4L44XUkhM1eYbD8fyEsxcV81pqMSR5gblfcLCHfZvbrqy4/qYHE+/R5HoBUT11WV5O08Cr1n3YXkWVQ==",
+ "dependencies": {
+ "core-util-is": "~1.0.0",
+ "inherits": "~2.0.1",
+ "isarray": "0.0.1",
+ "string_decoder": "~0.10.x"
+ }
+ },
"node_modules/readdirp": {
"version": "3.6.0",
"resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz",
@@ -941,6 +1108,11 @@
"node": ">=8.10.0"
}
},
+ "node_modules/requires-port": {
+ "version": "1.0.0",
+ "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz",
+ "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ=="
+ },
"node_modules/safe-buffer": {
"version": "5.2.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
@@ -1097,6 +1269,11 @@
"node": ">= 0.8"
}
},
+ "node_modules/string_decoder": {
+ "version": "0.10.31",
+ "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz",
+ "integrity": "sha512-ev2QzSzWPYmy9GuqfIVildA4OdcGLeFZQrq5ys6RtiuF+RQQiZWr8TZNyAcuVXyQRYfEO+MsoB/1BuQVhOJuoQ=="
+ },
"node_modules/supports-color": {
"version": "5.5.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz",
@@ -1171,6 +1348,15 @@
"node": ">= 0.8"
}
},
+ "node_modules/url-parse": {
+ "version": "1.5.10",
+ "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz",
+ "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==",
+ "dependencies": {
+ "querystringify": "^2.1.1",
+ "requires-port": "^1.0.0"
+ }
+ },
"node_modules/utils-merge": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz",
@@ -1222,6 +1408,14 @@
"optional": true
}
}
+ },
+ "node_modules/zod": {
+ "version": "3.23.8",
+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.23.8.tgz",
+ "integrity": "sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==",
+ "funding": {
+ "url": "https://github.com/sponsors/colinhacks"
+ }
}
}
}
diff --git a/backend/collaboration-service/package.json b/backend/collaboration-service/package.json
index 672f42109c..30df885cb8 100644
--- a/backend/collaboration-service/package.json
+++ b/backend/collaboration-service/package.json
@@ -10,12 +10,16 @@
"license": "ISC",
"description": "",
"dependencies": {
+ "@mistralai/mistralai": "^1.1.0",
+ "amqplib": "^0.10.4",
+ "axios": "^1.7.7",
"cors": "^2.8.5",
"dotenv": "^16.4.5",
"express": "^4.21.1",
"http": "^0.0.1-security",
"uuid": "^10.0.0",
- "ws": "^8.18.0"
+ "ws": "^8.18.0",
+ "zod": "^3.23.8"
},
"devDependencies": {
"nodemon": "^3.1.7"
diff --git a/backend/collaboration-service/routes/room.js b/backend/collaboration-service/routes/room.js
index 2674b511b5..e3a2ea40d6 100644
--- a/backend/collaboration-service/routes/room.js
+++ b/backend/collaboration-service/routes/room.js
@@ -7,6 +7,12 @@ const {
leaveRoom
} = require('../controllers/roomControllers');
+const {
+ askCopilot
+} = require('../controllers/copilotControllers');
+
+router.post('/', askCopilot);
+
router.post('/create', createRoom);
router.get('/:roomId', getRoomInfo);
router.post('/:roomId/join', joinRoom);
diff --git a/backend/collaboration-service/ws.js b/backend/collaboration-service/ws.js
index d2c3de7a77..56755c5cd0 100644
--- a/backend/collaboration-service/ws.js
+++ b/backend/collaboration-service/ws.js
@@ -290,6 +290,18 @@ function broadcastToRoom(roomId, message, excludeUserId = null) {
}
}
+// Helper function to send a message to a specific user by userId
+const sendWsMessage = (userId, message) => {
+ const ws = wsClients.get(userId);
+ if (ws) {
+ ws.send(JSON.stringify(message));
+ console.log(`Sent WebSocket message to user ${userId}:`, message);
+ } else {
+ console.log(`No WebSocket connection found for user ${userId}`);
+ }
+};
+
+
module.exports = {
- setupWebSocket,
+ setupWebSocket, sendWsMessage, broadcastToRoom
};
diff --git a/backend/matching-service/consumer.js b/backend/matching-service/consumer.js
index 1e50e2fd0e..93925c998d 100644
--- a/backend/matching-service/consumer.js
+++ b/backend/matching-service/consumer.js
@@ -1,3 +1,6 @@
+const { Mistral } = require('@mistralai/mistralai');
+
+
const amqp = require('amqplib/callback_api');
const { sendWsMessage } = require('./ws');
const axios = require('axios');
@@ -52,6 +55,29 @@ const setupConsumer = () => {
}
sendWsMessage(userRequest.userId, { status: 'CANCELLED' });
console.log(`Cancelled matching request for user ${userRequest.userId}`);
+ } else if (userRequest.status === 'askcopilot') {
+ // Handle askcopilot request: Call LLM API with the data
+ const apiKey = process.env.Mistral_API_KEY;
+ const client = new Mistral ({apiKey: apiKey});
+ const prompt = userRequest.data.prompt;
+ const code = userRequest.data.code;
+ model = 'mistral-large-latest'
+ chat_response = await client.chat.complete(
+
+ model=model,
+ messages=[
+ {
+ "role": "system",
+ "content": "You are an experienced developer. Please provide detailed and accurate responses."
+ },
+ {
+ "role": "user",
+ "content": "Prompt: ${prompt}\nCode: ${code}"
+ }
+ ]
+ )
+
+ sendWsMessage(userRequest.userId, { status: 'askcopilot', response: chat_response });
} else {
// Handle match request
const match = unmatchedUsers.find(u =>
diff --git a/frontend/src/api/CopilotApi.js b/frontend/src/api/CopilotApi.js
new file mode 100644
index 0000000000..c7cce564c4
--- /dev/null
+++ b/frontend/src/api/CopilotApi.js
@@ -0,0 +1,21 @@
+import axios from 'axios';
+
+const API_URL = 'http://localhost:8003/rooms';
+
+export const askCopilot = async (data) => {
+ try {
+ const response = await axios.post(API_URL, data);
+ if (response.status === 200) {
+ return response.data;
+ } else {
+ throw new Error('No match found.');
+ }
+ } catch (error) {
+ if (error.response) {
+ console.error('Error finding match:', error.response.data);
+ throw new Error(error.response.data.message);
+ }
+ console.error('Error finding match:', error);
+ throw error; // Re-throw the error to handle it in component
+ }
+}
\ No newline at end of file
diff --git a/frontend/src/pages/student/CollaborationRoom.js b/frontend/src/pages/student/CollaborationRoom.js
index 0b0aafcc05..2f8a1154da 100644
--- a/frontend/src/pages/student/CollaborationRoom.js
+++ b/frontend/src/pages/student/CollaborationRoom.js
@@ -1,6 +1,7 @@
import React, { useState, useEffect, useRef } from "react";
import Editor from "@monaco-editor/react";
import { useParams, useLocation } from "react-router-dom";
+import { askCopilot } from "../../api/CopilotApi";
const languages = [
{ label: "JavaScript", value: "javascript" },
@@ -27,7 +28,10 @@ const CollaborationRoom = () => {
const [ws, setWs] = useState(null); // Manage the WebSocket connection here.
const [code, setCode] = useState("// Start coding...");
const [language, setLanguage] = useState("javascript");
-
+
+ const [userPrompt, setUserPrompt] = useState(""); // Track the user input for the prompt
+ const [copilotResponse, setCopilotResponse] = useState(""); // Store the response from Copilot API
+
const monacoRef = useRef(null); // Store reference to Monaco instance
const editorRef = useRef(null); // Store reference to Monaco Editor instance
@@ -82,6 +86,8 @@ const CollaborationRoom = () => {
setStatus(`Failed to create room: ${result.message}`);
} else if (result.type === "LANGUAGE_CHANGE") {
setLanguage(result.language);
+ } else if (result.type === "ASK_COPILOT") {
+ setCopilotResponse(result.response);
}
};
@@ -192,6 +198,24 @@ const CollaborationRoom = () => {
}
};
+ const handleSubmitPrompt = async () => {
+ const promptData = {
+ code: code,
+ prompt: userPrompt,
+ type: "ASK_COPILOT",
+ roomId: roomId,
+ };
+
+ try {
+ const response = await askCopilot(promptData);
+
+ } catch (error) {
+ console.error("Error calling Copilot API:", error);
+ setCopilotResponse("Error: " + error);
+ }
+ };
+
+
console.log("Message:", message);
console.log("Messages:", messages);
@@ -247,6 +271,20 @@ const CollaborationRoom = () => {
>
+
+
+
+
Copilot Response:
+
{copilotResponse}
+
);
diff --git a/node_modules/.package-lock.json b/node_modules/.package-lock.json
new file mode 100644
index 0000000000..8e789618b6
--- /dev/null
+++ b/node_modules/.package-lock.json
@@ -0,0 +1,23 @@
+{
+ "name": "cs3219-ay2425s1-project-g19-3",
+ "lockfileVersion": 2,
+ "requires": true,
+ "packages": {
+ "node_modules/@mistralai/mistralai": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/@mistralai/mistralai/-/mistralai-1.1.0.tgz",
+ "integrity": "sha512-YueaIX+g4+QTX6ERLjZLZMOhlC0/EoqwpayWrUKfTM9EGTyiOPdxFLpLpg5B9PsaxOrmZDC88pOp4QgSMqVr8w==",
+ "peerDependencies": {
+ "zod": ">= 3"
+ }
+ },
+ "node_modules/zod": {
+ "version": "3.23.8",
+ "resolved": "https://registry.npmjs.org/zod/-/zod-3.23.8.tgz",
+ "integrity": "sha512-XBx9AXhXktjUqnepgTiE5flcKIYWi/rme0Eaj+5Y0lftuGBq+jyRu/md4WnuxqgP1ubdpNCsYEYPxrzVHD8d6g==",
+ "funding": {
+ "url": "https://github.com/sponsors/colinhacks"
+ }
+ }
+ }
+}
diff --git a/node_modules/.yarn-integrity b/node_modules/.yarn-integrity
new file mode 100644
index 0000000000..0fa476d719
--- /dev/null
+++ b/node_modules/.yarn-integrity
@@ -0,0 +1,16 @@
+{
+ "systemParams": "darwin-arm64-111",
+ "modulesFolders": [
+ "node_modules"
+ ],
+ "flags": [],
+ "linkedModules": [],
+ "topLevelPatterns": [
+ "@mistralai/mistralai@^1.1.0"
+ ],
+ "lockfileEntries": {
+ "@mistralai/mistralai@^1.1.0": "https://registry.yarnpkg.com/@mistralai/mistralai/-/mistralai-1.1.0.tgz#687dbb10078d45f5fb5d805a75c7774ad121e402"
+ },
+ "files": [],
+ "artifacts": {}
+}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/.devcontainer/README.md b/node_modules/@mistralai/mistralai/.devcontainer/README.md
new file mode 100644
index 0000000000..9832db9d14
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/.devcontainer/README.md
@@ -0,0 +1,35 @@
+
+
+
+
+
+
+> **Remember to shutdown a GitHub Codespace when it is not in use!**
+
+# Dev Containers Quick Start
+
+The default location for usage snippets is the `samples` directory.
+
+## Running a Usage Sample
+
+A sample usage example has been provided in a `root.ts` file. As you work with the SDK, it's expected that you will modify these samples to fit your needs. To execute this particular snippet, use the command below.
+
+```
+ts-node root.ts
+```
+
+## Generating Additional Usage Samples
+
+The speakeasy CLI allows you to generate more usage snippets. Here's how:
+
+- To generate a sample for a specific operation by providing an operation ID, use:
+
+```
+speakeasy generate usage -s registry.speakeasyapi.dev/mistral-dev/mistral-dev/mistral-openapi -l typescript -i {INPUT_OPERATION_ID} -o ./samples
+```
+
+- To generate samples for an entire namespace (like a tag or group name), use:
+
+```
+speakeasy generate usage -s registry.speakeasyapi.dev/mistral-dev/mistral-dev/mistral-openapi -l typescript -n {INPUT_TAG_NAME} -o ./samples
+```
diff --git a/node_modules/@mistralai/mistralai/LICENSE b/node_modules/@mistralai/mistralai/LICENSE
new file mode 100644
index 0000000000..bec1276803
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/LICENSE
@@ -0,0 +1,201 @@
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright 2024 Mistral AI
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/node_modules/@mistralai/mistralai/README.md b/node_modules/@mistralai/mistralai/README.md
new file mode 100644
index 0000000000..f19521cdd0
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/README.md
@@ -0,0 +1,646 @@
+# Mistral Typescript Client
+
+
+## Summary
+
+Mistral AI API: Our Chat Completion and Embeddings APIs specification. Create your account on [La Plateforme](https://console.mistral.ai) to get access and read the [docs](https://docs.mistral.ai) to learn how to use it.
+
+
+
+## Table of Contents
+
+* [SDK Installation](#sdk-installation)
+* [Requirements](#requirements)
+* [SDK Example Usage](#sdk-example-usage)
+* [Available Resources and Operations](#available-resources-and-operations)
+* [Standalone functions](#standalone-functions)
+* [Server-sent event streaming](#server-sent-event-streaming)
+* [File uploads](#file-uploads)
+* [Retries](#retries)
+* [Error Handling](#error-handling)
+* [Server Selection](#server-selection)
+* [Custom HTTP Client](#custom-http-client)
+* [Authentication](#authentication)
+* [Debugging](#debugging)
+
+
+
+## SDK Installation
+
+The SDK can be installed with either [npm](https://www.npmjs.com/), [pnpm](https://pnpm.io/), [bun](https://bun.sh/) or [yarn](https://classic.yarnpkg.com/en/) package managers.
+
+### NPM
+
+```bash
+npm add @mistralai/mistralai
+```
+
+### PNPM
+
+```bash
+pnpm add @mistralai/mistralai
+```
+
+### Bun
+
+```bash
+bun add @mistralai/mistralai
+```
+
+### Yarn
+
+```bash
+yarn add @mistralai/mistralai zod
+
+# Note that Yarn does not install peer dependencies automatically. You will need
+# to install zod as shown above.
+```
+
+
+
+## Requirements
+
+For supported JavaScript runtimes, please consult [RUNTIMES.md](RUNTIMES.md).
+
+
+## API Key Setup
+
+Before you begin, you will need a Mistral AI API key.
+
+1. Get your own Mistral API Key:
+2. Set your Mistral API Key as an environment variable. You only need to do this once.
+
+```bash
+# set Mistral API Key (using zsh for example)
+$ echo 'export MISTRAL_API_KEY=[your_key_here]' >> ~/.zshenv
+
+# reload the environment (or just quit and open a new terminal)
+$ source ~/.zshenv
+```
+
+
+## SDK Example Usage
+
+### Create Chat Completions
+
+This example shows how to create chat completions.
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.chat.complete({
+ model: "mistral-small-latest",
+ messages: [
+ {
+ content:
+ "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ });
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+### Upload a file
+
+This example shows how to upload a file.
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+import { openAsBlob } from "node:fs";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.files.upload({
+ file: await openAsBlob("example.file"),
+ });
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+### Create Agents Completions
+
+This example shows how to create agents completions.
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.agents.complete({
+ messages: [
+ {
+ content:
+ "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ agentId: "",
+ });
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+
+## Providers' SDKs
+
+We have dedicated SDKs for the following providers:
+
+- [GCP](/packages/mistralai-gcp/README.md)
+- [Azure](/packages/mistralai-azure/README.md)
+
+
+## Available Resources and Operations
+
+
+Available methods
+
+### [agents](docs/sdks/agents/README.md)
+
+* [complete](docs/sdks/agents/README.md#complete) - Agents Completion
+* [stream](docs/sdks/agents/README.md#stream) - Stream Agents completion
+
+### [chat](docs/sdks/chat/README.md)
+
+* [complete](docs/sdks/chat/README.md#complete) - Chat Completion
+* [stream](docs/sdks/chat/README.md#stream) - Stream chat completion
+
+### [embeddings](docs/sdks/embeddings/README.md)
+
+* [create](docs/sdks/embeddings/README.md#create) - Embeddings
+
+### [files](docs/sdks/files/README.md)
+
+* [upload](docs/sdks/files/README.md#upload) - Upload File
+* [list](docs/sdks/files/README.md#list) - List Files
+* [retrieve](docs/sdks/files/README.md#retrieve) - Retrieve File
+* [delete](docs/sdks/files/README.md#delete) - Delete File
+
+### [fim](docs/sdks/fim/README.md)
+
+* [complete](docs/sdks/fim/README.md#complete) - Fim Completion
+* [stream](docs/sdks/fim/README.md#stream) - Stream fim completion
+
+### [fineTuning](docs/sdks/finetuning/README.md)
+
+
+#### [fineTuning.jobs](docs/sdks/jobs/README.md)
+
+* [list](docs/sdks/jobs/README.md#list) - Get Fine Tuning Jobs
+* [create](docs/sdks/jobs/README.md#create) - Create Fine Tuning Job
+* [get](docs/sdks/jobs/README.md#get) - Get Fine Tuning Job
+* [cancel](docs/sdks/jobs/README.md#cancel) - Cancel Fine Tuning Job
+* [start](docs/sdks/jobs/README.md#start) - Start Fine Tuning Job
+
+
+### [models](docs/sdks/models/README.md)
+
+* [list](docs/sdks/models/README.md#list) - List Models
+* [retrieve](docs/sdks/models/README.md#retrieve) - Retrieve Model
+* [delete](docs/sdks/models/README.md#delete) - Delete Model
+* [update](docs/sdks/models/README.md#update) - Update Fine Tuned Model
+* [archive](docs/sdks/models/README.md#archive) - Archive Fine Tuned Model
+* [unarchive](docs/sdks/models/README.md#unarchive) - Unarchive Fine Tuned Model
+
+
+
+
+
+## Server-sent event streaming
+
+[Server-sent events][mdn-sse] are used to stream content from certain
+operations. These operations will expose the stream as an async iterable that
+can be consumed using a [`for await...of`][mdn-for-await-of] loop. The loop will
+terminate when the server no longer has any events to send and closes the
+underlying connection.
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.chat.stream({
+ model: "mistral-small-latest",
+ messages: [
+ {
+ content:
+ "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ });
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+
+```
+
+[mdn-sse]: https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events
+[mdn-for-await-of]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of
+
+
+
+## File uploads
+
+Certain SDK methods accept files as part of a multi-part request. It is possible and typically recommended to upload files as a stream rather than reading the entire contents into memory. This avoids excessive memory consumption and potentially crashing with out-of-memory errors when working with very large files. The following example demonstrates how to attach a file stream to a request.
+
+> [!TIP]
+>
+> Depending on your JavaScript runtime, there are convenient utilities that return a handle to a file without reading the entire contents into memory:
+>
+> - **Node.js v20+:** Since v20, Node.js comes with a native `openAsBlob` function in [`node:fs`](https://nodejs.org/docs/latest-v20.x/api/fs.html#fsopenasblobpath-options).
+> - **Bun:** The native [`Bun.file`](https://bun.sh/docs/api/file-io#reading-files-bun-file) function produces a file handle that can be used for streaming file uploads.
+> - **Browsers:** All supported browsers return an instance to a [`File`](https://developer.mozilla.org/en-US/docs/Web/API/File) when reading the value from an `` element.
+> - **Node.js v18:** A file stream can be created using the `fileFrom` helper from [`fetch-blob/from.js`](https://www.npmjs.com/package/fetch-blob).
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+import { openAsBlob } from "node:fs";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.files.upload({
+ file: await openAsBlob("example.file"),
+ });
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+
+
+## Retries
+
+Some of the endpoints in this SDK support retries. If you use the SDK without any configuration, it will fall back to the default retry strategy provided by the API. However, the default retry strategy can be overridden on a per-operation basis, or across the entire SDK.
+
+To change the default retry strategy for a single API call, simply provide a retryConfig object to the call:
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.list({
+ retries: {
+ strategy: "backoff",
+ backoff: {
+ initialInterval: 1,
+ maxInterval: 50,
+ exponent: 1.1,
+ maxElapsedTime: 100,
+ },
+ retryConnectionErrors: false,
+ },
+ });
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+If you'd like to override the default retry strategy for all operations that support retries, you can provide a retryConfig at SDK initialization:
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ retryConfig: {
+ strategy: "backoff",
+ backoff: {
+ initialInterval: 1,
+ maxInterval: 50,
+ exponent: 1.1,
+ maxElapsedTime: 100,
+ },
+ retryConnectionErrors: false,
+ },
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.list();
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+
+
+## Error Handling
+
+All SDK methods return a response object or throw an error. If Error objects are specified in your OpenAPI Spec, the SDK will throw the appropriate Error type.
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+Validation errors can also occur when either method arguments or data returned from the server do not match the expected format. The `SDKValidationError` that is thrown as a result will capture the raw value that failed validation in an attribute called `rawValue`. Additionally, a `pretty()` method is available on this error that can be used to log a nicely formatted string since validation errors can list many issues and the plain error string may be difficult read when debugging.
+
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+import {
+ HTTPValidationError,
+ SDKValidationError,
+} from "@mistralai/mistralai/models/errors";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ let result;
+ try {
+ result = await mistral.models.list();
+
+ // Handle the result
+ console.log(result);
+ } catch (err) {
+ switch (true) {
+ case (err instanceof SDKValidationError): {
+ // Validation errors can be pretty-printed
+ console.error(err.pretty());
+ // Raw value may also be inspected
+ console.error(err.rawValue);
+ return;
+ }
+ case (err instanceof HTTPValidationError): {
+ // Handle err.data$: HTTPValidationErrorData
+ console.error(err);
+ return;
+ }
+ default: {
+ throw err;
+ }
+ }
+ }
+}
+
+run();
+
+```
+
+
+
+## Server Selection
+
+### Select Server by Name
+
+You can override the default server globally by passing a server name to the `server` optional parameter when initializing the SDK client instance. The selected server will then be used as the default on the operations that use it. This table lists the names associated with the available servers:
+
+| Name | Server | Variables |
+| ----- | ------ | --------- |
+| `prod` | `https://api.mistral.ai` | None |
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ server: "prod",
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.list();
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+
+### Override Server URL Per-Client
+
+The default server can also be overridden globally by passing a URL to the `serverURL` optional parameter when initializing the SDK client instance. For example:
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ serverURL: "https://api.mistral.ai",
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.list();
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+
+
+## Custom HTTP Client
+
+The TypeScript SDK makes API calls using an `HTTPClient` that wraps the native
+[Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API). This
+client is a thin wrapper around `fetch` and provides the ability to attach hooks
+around the request lifecycle that can be used to modify the request or handle
+errors and response.
+
+The `HTTPClient` constructor takes an optional `fetcher` argument that can be
+used to integrate a third-party HTTP client or when writing tests to mock out
+the HTTP client and feed in fixtures.
+
+The following example shows how to use the `"beforeRequest"` hook to to add a
+custom header and a timeout to requests and how to use the `"requestError"` hook
+to log errors:
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+import { HTTPClient } from "@mistralai/mistralai/lib/http";
+
+const httpClient = new HTTPClient({
+ // fetcher takes a function that has the same signature as native `fetch`.
+ fetcher: (request) => {
+ return fetch(request);
+ }
+});
+
+httpClient.addHook("beforeRequest", (request) => {
+ const nextRequest = new Request(request, {
+ signal: request.signal || AbortSignal.timeout(5000)
+ });
+
+ nextRequest.headers.set("x-custom-header", "custom value");
+
+ return nextRequest;
+});
+
+httpClient.addHook("requestError", (error, request) => {
+ console.group("Request Error");
+ console.log("Reason:", `${error}`);
+ console.log("Endpoint:", `${request.method} ${request.url}`);
+ console.groupEnd();
+});
+
+const sdk = new Mistral({ httpClient });
+```
+
+
+
+## Authentication
+
+### Per-Client Security Schemes
+
+This SDK supports the following security scheme globally:
+
+| Name | Type | Scheme | Environment Variable |
+| -------------------- | -------------------- | -------------------- | -------------------- |
+| `apiKey` | http | HTTP Bearer | `MISTRAL_API_KEY` |
+
+To authenticate with the API the `apiKey` parameter must be set when initializing the SDK client instance. For example:
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.list();
+
+ // Handle the result
+ console.log(result);
+}
+
+run();
+
+```
+
+
+## Providers Support
+
+We also provide provider specific SDK for:
+
+- [GCP](packages/mistralai-gcp/README.md)
+- [Azure](packages/mistralai-azure/README.md)
+
+
+## Standalone functions
+
+All the methods listed above are available as standalone functions. These
+functions are ideal for use in applications running in the browser, serverless
+runtimes or other environments where application bundle size is a primary
+concern. When using a bundler to build your application, all unused
+functionality will be either excluded from the final bundle or tree-shaken away.
+
+To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
+
+
+
+Available standalone functions
+
+- [agentsComplete](docs/sdks/agents/README.md#complete)
+- [agentsStream](docs/sdks/agents/README.md#stream)
+- [chatComplete](docs/sdks/chat/README.md#complete)
+- [chatStream](docs/sdks/chat/README.md#stream)
+- [embeddingsCreate](docs/sdks/embeddings/README.md#create)
+- [filesDelete](docs/sdks/files/README.md#delete)
+- [filesList](docs/sdks/files/README.md#list)
+- [filesRetrieve](docs/sdks/files/README.md#retrieve)
+- [filesUpload](docs/sdks/files/README.md#upload)
+- [fimComplete](docs/sdks/fim/README.md#complete)
+- [fimStream](docs/sdks/fim/README.md#stream)
+- [fineTuningJobsCancel](docs/sdks/jobs/README.md#cancel)
+- [fineTuningJobsCreate](docs/sdks/jobs/README.md#create)
+- [fineTuningJobsGet](docs/sdks/jobs/README.md#get)
+- [fineTuningJobsList](docs/sdks/jobs/README.md#list)
+- [fineTuningJobsStart](docs/sdks/jobs/README.md#start)
+- [modelsArchive](docs/sdks/models/README.md#archive)
+- [modelsDelete](docs/sdks/models/README.md#delete)
+- [modelsList](docs/sdks/models/README.md#list)
+- [modelsRetrieve](docs/sdks/models/README.md#retrieve)
+- [modelsUnarchive](docs/sdks/models/README.md#unarchive)
+- [modelsUpdate](docs/sdks/models/README.md#update)
+
+
+
+
+
+
+## Debugging
+
+You can setup your SDK to emit debug logs for SDK requests and responses.
+
+You can pass a logger that matches `console`'s interface as an SDK option.
+
+> [!WARNING]
+> Beware that debug logging will reveal secrets, like API tokens in headers, in log messages printed to a console or files. It's recommended to use this feature only during local development and not in production.
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const sdk = new Mistral({ debugLogger: console });
+```
+
+You can also enable a default debug logger by setting an environment variable `MISTRAL_DEBUG` to true.
+
+
+
+
+# Development
+
+## Contributions
+
+While we value open-source contributions to this SDK, this library is generated programmatically. Any manual changes added to internal files will be overwritten on the next generation.
+We look forward to hearing your feedback. Feel free to open a PR or an issue with a proof of concept and we'll do our best to include it in a future release.
+
diff --git a/node_modules/@mistralai/mistralai/core.d.ts b/node_modules/@mistralai/mistralai/core.d.ts
new file mode 100644
index 0000000000..d89ee17bdf
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/core.d.ts
@@ -0,0 +1,10 @@
+import { ClientSDK } from "./lib/sdks.js";
+/**
+ * A minimal client to use when calling standalone SDK functions. Typically, an
+ * instance of this class would be instantiated once at the start of an
+ * application and passed around through some dependency injection mechanism to
+ * parts of an application that need to make SDK calls.
+ */
+export declare class MistralCore extends ClientSDK {
+}
+//# sourceMappingURL=core.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/core.d.ts.map b/node_modules/@mistralai/mistralai/core.d.ts.map
new file mode 100644
index 0000000000..5cd632f1cc
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/core.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"core.d.ts","sourceRoot":"","sources":["src/core.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE1C;;;;;GAKG;AACH,qBAAa,WAAY,SAAQ,SAAS;CAAG"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/core.js b/node_modules/@mistralai/mistralai/core.js
new file mode 100644
index 0000000000..1ceae3ca9a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/core.js
@@ -0,0 +1,17 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.MistralCore = void 0;
+const sdks_js_1 = require("./lib/sdks.js");
+/**
+ * A minimal client to use when calling standalone SDK functions. Typically, an
+ * instance of this class would be instantiated once at the start of an
+ * application and passed around through some dependency injection mechanism to
+ * parts of an application that need to make SDK calls.
+ */
+class MistralCore extends sdks_js_1.ClientSDK {
+}
+exports.MistralCore = MistralCore;
+//# sourceMappingURL=core.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/core.js.map b/node_modules/@mistralai/mistralai/core.js.map
new file mode 100644
index 0000000000..ea380df640
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/core.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"core.js","sourceRoot":"","sources":["src/core.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,2CAA0C;AAE1C;;;;;GAKG;AACH,MAAa,WAAY,SAAQ,mBAAS;CAAG;AAA7C,kCAA6C"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/agents/README.md b/node_modules/@mistralai/mistralai/docs/sdks/agents/README.md
new file mode 100644
index 0000000000..8d13d049ec
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/agents/README.md
@@ -0,0 +1,194 @@
+# Agents
+(*agents*)
+
+## Overview
+
+Agents API.
+
+### Available Operations
+
+* [complete](#complete) - Agents Completion
+* [stream](#stream) - Stream Agents completion
+
+## complete
+
+Agents Completion
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.agents.complete({
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ agentId: "",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { agentsComplete } from "@mistralai/mistralai/funcs/agentsComplete.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await agentsComplete(mistral, {
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ agentId: "",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.AgentsCompletionRequest](../../models/components/agentscompletionrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.ChatCompletionResponse](../../models/components/chatcompletionresponse.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## stream
+
+Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.agents.stream({
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ agentId: "",
+ });
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { agentsStream } from "@mistralai/mistralai/funcs/agentsStream.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await agentsStream(mistral, {
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ agentId: "",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.AgentsCompletionStreamRequest](../../models/components/agentscompletionstreamrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[EventStream](../../models/.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/chat/README.md b/node_modules/@mistralai/mistralai/docs/sdks/chat/README.md
new file mode 100644
index 0000000000..23efd76222
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/chat/README.md
@@ -0,0 +1,194 @@
+# Chat
+(*chat*)
+
+## Overview
+
+Chat Completion API.
+
+### Available Operations
+
+* [complete](#complete) - Chat Completion
+* [stream](#stream) - Stream chat completion
+
+## complete
+
+Chat Completion
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.chat.complete({
+ model: "mistral-small-latest",
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { chatComplete } from "@mistralai/mistralai/funcs/chatComplete.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await chatComplete(mistral, {
+ model: "mistral-small-latest",
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.ChatCompletionRequest](../../models/components/chatcompletionrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.ChatCompletionResponse](../../models/components/chatcompletionresponse.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## stream
+
+Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.chat.stream({
+ model: "mistral-small-latest",
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ });
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { chatStream } from "@mistralai/mistralai/funcs/chatStream.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await chatStream(mistral, {
+ model: "mistral-small-latest",
+ messages: [
+ {
+ content: "Who is the best French painter? Answer in one short sentence.",
+ role: "user",
+ },
+ ],
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.ChatCompletionStreamRequest](../../models/components/chatcompletionstreamrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[EventStream](../../models/.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/embeddings/README.md b/node_modules/@mistralai/mistralai/docs/sdks/embeddings/README.md
new file mode 100644
index 0000000000..1a534eb98f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/embeddings/README.md
@@ -0,0 +1,89 @@
+# Embeddings
+(*embeddings*)
+
+## Overview
+
+Embeddings API.
+
+### Available Operations
+
+* [create](#create) - Embeddings
+
+## create
+
+Embeddings
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.embeddings.create({
+ inputs: "",
+ model: "Wrangler",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { embeddingsCreate } from "@mistralai/mistralai/funcs/embeddingsCreate.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await embeddingsCreate(mistral, {
+ inputs: "",
+ model: "Wrangler",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.EmbeddingRequest](../../models/components/embeddingrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.EmbeddingResponse](../../models/components/embeddingresponse.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/files/README.md b/node_modules/@mistralai/mistralai/docs/sdks/files/README.md
new file mode 100644
index 0000000000..624553e6b1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/files/README.md
@@ -0,0 +1,321 @@
+# Files
+(*files*)
+
+## Overview
+
+Files API
+
+### Available Operations
+
+* [upload](#upload) - Upload File
+* [list](#list) - List Files
+* [retrieve](#retrieve) - Retrieve File
+* [delete](#delete) - Delete File
+
+## upload
+
+Upload a file that can be used across various endpoints.
+
+The size of individual files can be a maximum of 512 MB. The Fine-tuning API only supports .jsonl files.
+
+Please contact us if you need to increase these storage limits.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+import { openAsBlob } from "node:fs";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.files.upload({
+ file: await openAsBlob("example.file"),
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { filesUpload } from "@mistralai/mistralai/funcs/filesUpload.js";
+import { openAsBlob } from "node:fs";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await filesUpload(mistral, {
+ file: await openAsBlob("example.file"),
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.FilesApiRoutesUploadFileMultiPartBodyParams](../../models/operations/filesapiroutesuploadfilemultipartbodyparams.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.UploadFileOut](../../models/components/uploadfileout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## list
+
+Returns a list of files that belong to the user's organization.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.files.list();
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { filesList } from "@mistralai/mistralai/funcs/filesList.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await filesList(mistral);
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.ListFilesOut](../../models/components/listfilesout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## retrieve
+
+Returns information about a specific file.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.files.retrieve({
+ fileId: "",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { filesRetrieve } from "@mistralai/mistralai/funcs/filesRetrieve.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await filesRetrieve(mistral, {
+ fileId: "",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.FilesApiRoutesRetrieveFileRequest](../../models/operations/filesapiroutesretrievefilerequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.RetrieveFileOut](../../models/components/retrievefileout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## delete
+
+Delete a file.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.files.delete({
+ fileId: "",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { filesDelete } from "@mistralai/mistralai/funcs/filesDelete.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await filesDelete(mistral, {
+ fileId: "",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.FilesApiRoutesDeleteFileRequest](../../models/operations/filesapiroutesdeletefilerequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.DeleteFileOut](../../models/components/deletefileout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/fim/README.md b/node_modules/@mistralai/mistralai/docs/sdks/fim/README.md
new file mode 100644
index 0000000000..d097ad9b17
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/fim/README.md
@@ -0,0 +1,178 @@
+# Fim
+(*fim*)
+
+## Overview
+
+Fill-in-the-middle API.
+
+### Available Operations
+
+* [complete](#complete) - Fim Completion
+* [stream](#stream) - Stream fim completion
+
+## complete
+
+FIM completion.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fim.complete({
+ model: "codestral-2405",
+ prompt: "def",
+ suffix: "return a+b",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fimComplete } from "@mistralai/mistralai/funcs/fimComplete.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fimComplete(mistral, {
+ model: "codestral-2405",
+ prompt: "def",
+ suffix: "return a+b",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.FIMCompletionRequest](../../models/components/fimcompletionrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.FIMCompletionResponse](../../models/components/fimcompletionresponse.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## stream
+
+Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fim.stream({
+ model: "codestral-2405",
+ prompt: "def",
+ suffix: "return a+b",
+ });
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fimStream } from "@mistralai/mistralai/funcs/fimStream.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fimStream(mistral, {
+ model: "codestral-2405",
+ prompt: "def",
+ suffix: "return a+b",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ for await (const event of result) {
+ // Handle the event
+ console.log(event);
+ }
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.FIMCompletionStreamRequest](../../models/components/fimcompletionstreamrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[EventStream](../../models/.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/finetuning/README.md b/node_modules/@mistralai/mistralai/docs/sdks/finetuning/README.md
new file mode 100644
index 0000000000..f3d0196320
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/finetuning/README.md
@@ -0,0 +1,2 @@
+# FineTuning
+(*fineTuning*)
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/jobs/README.md b/node_modules/@mistralai/mistralai/docs/sdks/jobs/README.md
new file mode 100644
index 0000000000..db8b050067
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/jobs/README.md
@@ -0,0 +1,394 @@
+# Jobs
+(*fineTuning.jobs*)
+
+## Overview
+
+### Available Operations
+
+* [list](#list) - Get Fine Tuning Jobs
+* [create](#create) - Create Fine Tuning Job
+* [get](#get) - Get Fine Tuning Job
+* [cancel](#cancel) - Cancel Fine Tuning Job
+* [start](#start) - Start Fine Tuning Job
+
+## list
+
+Get a list of fine-tuning jobs for your organization and user.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fineTuning.jobs.list();
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fineTuningJobsList } from "@mistralai/mistralai/funcs/fineTuningJobsList.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fineTuningJobsList(mistral);
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningGetFineTuningJobsRequest](../../models/operations/jobsapiroutesfinetuninggetfinetuningjobsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.JobsOut](../../models/components/jobsout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## create
+
+Create a new fine-tuning job, it will be queued for processing.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fineTuning.jobs.create({
+ model: "codestral-latest",
+ hyperparameters: {},
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fineTuningJobsCreate } from "@mistralai/mistralai/funcs/fineTuningJobsCreate.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fineTuningJobsCreate(mistral, {
+ model: "codestral-latest",
+ hyperparameters: {},
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [components.JobIn](../../models/components/jobin.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[operations.JobsApiRoutesFineTuningCreateFineTuningJobResponse](../../models/operations/jobsapiroutesfinetuningcreatefinetuningjobresponse.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## get
+
+Get a fine-tuned job details by its UUID.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fineTuning.jobs.get({
+ jobId: "b18d8d81-fd7b-4764-a31e-475cb1f36591",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fineTuningJobsGet } from "@mistralai/mistralai/funcs/fineTuningJobsGet.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fineTuningJobsGet(mistral, {
+ jobId: "b18d8d81-fd7b-4764-a31e-475cb1f36591",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningGetFineTuningJobRequest](../../models/operations/jobsapiroutesfinetuninggetfinetuningjobrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.DetailedJobOut](../../models/components/detailedjobout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## cancel
+
+Request the cancellation of a fine tuning job.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fineTuning.jobs.cancel({
+ jobId: "03fa7112-315a-4072-a9f2-43f3f1ec962e",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fineTuningJobsCancel } from "@mistralai/mistralai/funcs/fineTuningJobsCancel.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fineTuningJobsCancel(mistral, {
+ jobId: "03fa7112-315a-4072-a9f2-43f3f1ec962e",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningCancelFineTuningJobRequest](../../models/operations/jobsapiroutesfinetuningcancelfinetuningjobrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.DetailedJobOut](../../models/components/detailedjobout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## start
+
+Request the start of a validated fine tuning job.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.fineTuning.jobs.start({
+ jobId: "0eb0f807-fb9f-4e46-9c13-4e257df6e1ba",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { fineTuningJobsStart } from "@mistralai/mistralai/funcs/fineTuningJobsStart.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await fineTuningJobsStart(mistral, {
+ jobId: "0eb0f807-fb9f-4e46-9c13-4e257df6e1ba",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningStartFineTuningJobRequest](../../models/operations/jobsapiroutesfinetuningstartfinetuningjobrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.DetailedJobOut](../../models/components/detailedjobout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/mistral/README.md b/node_modules/@mistralai/mistralai/docs/sdks/mistral/README.md
new file mode 100644
index 0000000000..0189a6c487
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/mistral/README.md
@@ -0,0 +1,5 @@
+# Mistral SDK
+
+## Overview
+
+Mistral AI API: Our Chat Completion and Embeddings APIs specification. Create your account on [La Plateforme](https://console.mistral.ai) to get access and read the [docs](https://docs.mistral.ai) to learn how to use it.
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/docs/sdks/models/README.md b/node_modules/@mistralai/mistralai/docs/sdks/models/README.md
new file mode 100644
index 0000000000..61d549920c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/docs/sdks/models/README.md
@@ -0,0 +1,476 @@
+# Models
+(*models*)
+
+## Overview
+
+Model Management API
+
+### Available Operations
+
+* [list](#list) - List Models
+* [retrieve](#retrieve) - Retrieve Model
+* [delete](#delete) - Delete Model
+* [update](#update) - Update Fine Tuned Model
+* [archive](#archive) - Archive Fine Tuned Model
+* [unarchive](#unarchive) - Unarchive Fine Tuned Model
+
+## list
+
+List all models available to the user.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.list();
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { modelsList } from "@mistralai/mistralai/funcs/modelsList.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await modelsList(mistral);
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.ModelList](../../models/components/modellist.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## retrieve
+
+Retrieve a model information.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.retrieve({
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { modelsRetrieve } from "@mistralai/mistralai/funcs/modelsRetrieve.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await modelsRetrieve(mistral, {
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.RetrieveModelV1ModelsModelIdGetRequest](../../models/operations/retrievemodelv1modelsmodelidgetrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[operations.RetrieveModelV1ModelsModelIdGetResponseRetrieveModelV1ModelsModelIdGet](../../models/operations/retrievemodelv1modelsmodelidgetresponseretrievemodelv1modelsmodelidget.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## delete
+
+Delete a fine-tuned model.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.delete({
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { modelsDelete } from "@mistralai/mistralai/funcs/modelsDelete.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await modelsDelete(mistral, {
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.DeleteModelV1ModelsModelIdDeleteRequest](../../models/operations/deletemodelv1modelsmodeliddeleterequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.DeleteModelOut](../../models/components/deletemodelout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| -------------------------- | -------------------------- | -------------------------- |
+| errors.HTTPValidationError | 422 | application/json |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## update
+
+Update a model name or description.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.update({
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ updateFTModelIn: {},
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { modelsUpdate } from "@mistralai/mistralai/funcs/modelsUpdate.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await modelsUpdate(mistral, {
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ updateFTModelIn: {},
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningUpdateFineTunedModelRequest](../../models/operations/jobsapiroutesfinetuningupdatefinetunedmodelrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.FTModelOut](../../models/components/ftmodelout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## archive
+
+Archive a fine-tuned model.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.archive({
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { modelsArchive } from "@mistralai/mistralai/funcs/modelsArchive.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await modelsArchive(mistral, {
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningArchiveFineTunedModelRequest](../../models/operations/jobsapiroutesfinetuningarchivefinetunedmodelrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.ArchiveFTModelOut](../../models/components/archiveftmodelout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
+
+
+## unarchive
+
+Un-archive a fine-tuned model.
+
+### Example Usage
+
+```typescript
+import { Mistral } from "@mistralai/mistralai";
+
+const mistral = new Mistral({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const result = await mistral.models.unarchive({
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Standalone function
+
+The standalone function version of this method:
+
+```typescript
+import { MistralCore } from "@mistralai/mistralai/core.js";
+import { modelsUnarchive } from "@mistralai/mistralai/funcs/modelsUnarchive.js";
+
+// Use `MistralCore` for best tree-shaking performance.
+// You can create one instance of it to use across an application.
+const mistral = new MistralCore({
+ apiKey: process.env["MISTRAL_API_KEY"] ?? "",
+});
+
+async function run() {
+ const res = await modelsUnarchive(mistral, {
+ modelId: "ft:open-mistral-7b:587a6b29:20240514:7e773925",
+ });
+
+ if (!res.ok) {
+ throw res.error;
+ }
+
+ const { value: result } = res;
+
+ // Handle the result
+ console.log(result)
+}
+
+run();
+```
+
+### Parameters
+
+| Parameter | Type | Required | Description |
+| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+| `request` | [operations.JobsApiRoutesFineTuningUnarchiveFineTunedModelRequest](../../models/operations/jobsapiroutesfinetuningunarchivefinetunedmodelrequest.md) | :heavy_check_mark: | The request object to use for the request. |
+| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
+| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
+| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
+
+### Response
+
+**Promise\<[components.UnarchiveFTModelOut](../../models/components/unarchiveftmodelout.md)\>**
+
+### Errors
+
+| Error Object | Status Code | Content Type |
+| --------------- | --------------- | --------------- |
+| errors.SDKError | 4xx-5xx | */* |
diff --git a/node_modules/@mistralai/mistralai/examples/README.md b/node_modules/@mistralai/mistralai/examples/README.md
new file mode 100644
index 0000000000..ea97d7af36
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/README.md
@@ -0,0 +1,29 @@
+# Examples
+
+Below is a guide how to run the examples if you have cloned this repo.
+
+## Prerequisites
+
+- Node.js v18+
+- `cp .env.template .env` and fill in the fields corresponding to the examples you want to run.
+
+## Install
+
+- You'll need to run `npm install` in the root of the repository
+- You'll need to run `npm install` in `packages/gcp` directory
+- You'll need to run `npm install` in `packages/azure` directory
+- Finally, you'll need to run `npm install` in this `examples` directory
+
+## Run
+
+```
+npm run script -- ./src/chat_streaming.ts
+```
+
+## Test
+
+The following will run all `examples` directory:
+
+```
+npm run test
+```
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_chat_no_streaming.ts b/node_modules/@mistralai/mistralai/examples/src/async_chat_no_streaming.ts
new file mode 100644
index 0000000000..47749cec8e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_chat_no_streaming.ts
@@ -0,0 +1,15 @@
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const client = new Mistral({ apiKey: apiKey });
+
+const chatResponse = await client.chat.complete({
+ model: "mistral-tiny",
+ messages: [{ role: "user", content: "What is the best French cheese?" }],
+});
+
+console.log("Chat:", chatResponse);
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_chat_streaming.ts b/node_modules/@mistralai/mistralai/examples/src/async_chat_streaming.ts
new file mode 100644
index 0000000000..b13aab7feb
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_chat_streaming.ts
@@ -0,0 +1,27 @@
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const mistral = new Mistral({ apiKey: apiKey });
+
+const stream = await mistral.chat.stream({
+ model: "mistral-tiny",
+ messages: [
+ {
+ role: "user",
+ content: "What is the best French cheese?",
+ },
+ ],
+});
+
+for await (const event of stream) {
+ const content = event.data?.choices[0]?.delta.content;
+ if (!content) {
+ continue;
+ }
+
+ process.stdout.write(content);
+}
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_embeddings.ts b/node_modules/@mistralai/mistralai/examples/src/async_embeddings.ts
new file mode 100644
index 0000000000..9fafde55a7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_embeddings.ts
@@ -0,0 +1,20 @@
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const client = new Mistral({ apiKey: apiKey });
+
+const inputs = [];
+for (let i = 0; i < 1; i++) {
+ inputs.push("What is the best French cheese?");
+}
+
+const embeddingsBatchResponse = await client.embeddings.create({
+ model: "mistral-embed",
+ inputs: inputs,
+});
+
+console.log("Embeddings Batch:", embeddingsBatchResponse.data);
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_files.ts b/node_modules/@mistralai/mistralai/examples/src/async_files.ts
new file mode 100644
index 0000000000..c77f2554fb
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_files.ts
@@ -0,0 +1,36 @@
+import * as fs from "fs";
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const client = new Mistral({ apiKey: apiKey });
+
+// Create a new file
+const blob = new Blob([fs.readFileSync("./src/file.jsonl")], {
+ type: "application/json",
+});
+const createdFile = await client.files.upload({ file: blob, });
+// const createdFile = await client.files.upload(
+// {
+// file: {
+// fileName: "./src/file.jsonl",
+// content: fs.readFileSync("./src/file.jsonl")
+// },
+// });
+
+console.log(createdFile);
+
+// List files
+const files = await client.files.list();
+console.log(files);
+
+// Retrieve a file
+const retrievedFile = await client.files.retrieve({ fileId: createdFile.id });
+console.log(retrievedFile);
+
+// Delete a file
+const deletedFile = await client.files.delete({ fileId: createdFile.id });
+console.log(deletedFile);
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_function_calling.ts b/node_modules/@mistralai/mistralai/examples/src/async_function_calling.ts
new file mode 100644
index 0000000000..382e555a16
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_function_calling.ts
@@ -0,0 +1,147 @@
+import { Mistral } from "@mistralai/mistralai";
+import { UserMessage } from "@mistralai/mistralai/models/components/usermessage.js";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+// Assuming we have the following data
+const data = {
+ transactionId: ["T1001", "T1002", "T1003", "T1004", "T1005"],
+ customerId: ["C001", "C002", "C003", "C002", "C001"],
+ paymentAmount: [125.5, 89.99, 120.0, 54.3, 210.2],
+ paymentDate: [
+ "2021-10-05",
+ "2021-10-06",
+ "2021-10-07",
+ "2021-10-05",
+ "2021-10-08",
+ ],
+ paymentStatus: ["Paid", "Unpaid", "Paid", "Paid", "Pending"],
+};
+
+/**
+ * This function retrieves the payment status of a transaction id.
+ * @param {object} data - The data object.
+ * @param {string} transactionId - The transaction id.
+ * @return {string} - The payment status.
+ */
+function retrievePaymentStatus({ data, transactionId }) {
+ const transactionIndex = data.transactionId.indexOf(transactionId);
+ if (transactionIndex != -1) {
+ return JSON.stringify({ status: data.paymentStatus[transactionIndex] });
+ } else {
+ return JSON.stringify({ status: "error - transaction id not found." });
+ }
+}
+
+/**
+ * This function retrieves the payment date of a transaction id.
+ * @param {object} data - The data object.
+ * @param {string} transactionId - The transaction id.
+ * @return {string} - The payment date.
+ *
+ */
+function retrievePaymentDate({ data, transactionId }) {
+ const transactionIndex = data.transactionId.indexOf(transactionId);
+ if (transactionIndex != -1) {
+ return JSON.stringify({ status: data.paymentDate[transactionIndex] });
+ } else {
+ return JSON.stringify({ status: "error - transaction id not found." });
+ }
+}
+
+const namesToFunctions = {
+ retrievePaymentStatus: (transactionId) =>
+ retrievePaymentStatus({ data, ...transactionId }),
+ retrievePaymentDate: (transactionId) =>
+ retrievePaymentDate({ data, ...transactionId }),
+};
+
+const tools = [
+ {
+ type: "function",
+ function: {
+ name: "retrievePaymentStatus",
+ description: "Get payment status of a transaction id",
+ parameters: {
+ type: "object",
+ required: ["transactionId"],
+ properties: {
+ transactionId: { type: "string", description: "The transaction id." },
+ },
+ },
+ },
+ },
+ {
+ type: "function",
+ function: {
+ name: "retrievePaymentDate",
+ description: "Get payment date of a transaction id",
+ parameters: {
+ type: "object",
+ required: ["transactionId"],
+ properties: {
+ transactionId: { type: "string", description: "The transaction id." },
+ },
+ },
+ },
+ },
+];
+
+const model = "mistral-large-latest";
+
+const client = new Mistral({ apiKey: apiKey });
+
+const messages = [
+ { role: "user", content: "What's the status of my transaction?" },
+];
+
+let response = await client.chat.complete({
+ model: model,
+ messages: messages,
+ tools: tools,
+});
+
+messages.push({
+ role: "assistant",
+ content: response.choices[0].message.content,
+});
+
+messages.push({ role: "user", content: "My transaction ID is T1001." });
+
+response = await client.chat.complete({
+ model: model,
+ messages: messages,
+ tools: tools,
+});
+
+messages.push(response.choices[0].message);
+
+const toolCalls = response.choices[0].message.toolCalls;
+for (const toolCall of toolCalls) {
+ const functionName = toolCall.function.name;
+ const functionParams = JSON.parse(toolCall.function.arguments);
+
+ console.log(`calling functionName: ${functionName}`);
+ console.log(`functionParams: ${toolCall.function.arguments}`);
+ const functionResult = namesToFunctions[functionName](functionParams);
+
+ messages.push({
+ role: "tool",
+ name: functionName,
+ content: functionResult,
+ tool_call_id: toolCall.id,
+ });
+}
+console.log(messages);
+console.log(tools);
+
+response = await client.chat.complete({
+ model: model,
+ messages: messages,
+ tools: tools,
+});
+
+console.log(response.choices[0].message.content);
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_function_calling_streaming.ts b/node_modules/@mistralai/mistralai/examples/src/async_function_calling_streaming.ts
new file mode 100644
index 0000000000..c3cc829739
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_function_calling_streaming.ts
@@ -0,0 +1,180 @@
+import { Mistral } from "@mistralai/mistralai";
+import { ToolCall } from "@mistralai/mistralai/models/components/toolcall.js";
+import { AssisantMessage } from "@mistralai/mistralai/components/assistantmessage.js";
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+// Assuming we have the following data
+const data = {
+ transactionId: ["T1001", "T1002", "T1003", "T1004", "T1005"],
+ customerId: ["C001", "C002", "C003", "C002", "C001"],
+ paymentAmount: [125.5, 89.99, 120.0, 54.3, 210.2],
+ paymentDate: [
+ "2021-10-05",
+ "2021-10-06",
+ "2021-10-07",
+ "2021-10-05",
+ "2021-10-08",
+ ],
+ paymentStatus: ["Paid", "Unpaid", "Paid", "Paid", "Pending"],
+};
+
+/**
+ * This function retrieves the payment status of a transaction id.
+ * @param {object} data - The data object.
+ * @param {string} transactionId - The transaction id.
+ * @return {string} - The payment status.
+ */
+function retrievePaymentStatus({ data, transactionId }) {
+ const transactionIndex = data.transactionId.indexOf(transactionId);
+ if (transactionIndex != -1) {
+ return JSON.stringify({ status: data.paymentStatus[transactionIndex] });
+ } else {
+ return JSON.stringify({ status: "error - transaction id not found." });
+ }
+}
+
+/**
+ * This function retrieves the payment date of a transaction id.
+ * @param {object} data - The data object.
+ * @param {string} transactionId - The transaction id.
+ * @return {string} - The payment date.
+ *
+ */
+function retrievePaymentDate({ data, transactionId }) {
+ const transactionIndex = data.transactionId.indexOf(transactionId);
+ if (transactionIndex != -1) {
+ return JSON.stringify({ status: data.paymentDate[transactionIndex] });
+ } else {
+ return JSON.stringify({ status: "error - transaction id not found." });
+ }
+}
+
+const namesToFunctions = {
+ retrievePaymentStatus: (transactionId) =>
+ retrievePaymentStatus({ data, ...transactionId }),
+ retrievePaymentDate: (transactionId) =>
+ retrievePaymentDate({ data, ...transactionId }),
+};
+
+const tools = [
+ {
+ type: "function",
+ function: {
+ name: "retrievePaymentStatus",
+ description: "Get payment status of a transaction id",
+ parameters: {
+ type: "object",
+ required: ["transactionId"],
+ properties: {
+ transactionId: { type: "string", description: "The transaction id." },
+ },
+ },
+ },
+ },
+ {
+ type: "function",
+ function: {
+ name: "retrievePaymentDate",
+ description: "Get payment date of a transaction id",
+ parameters: {
+ type: "object",
+ required: ["transactionId"],
+ properties: {
+ transactionId: { type: "string", description: "The transaction id." },
+ },
+ },
+ },
+ },
+];
+
+const model = "mistral-large-latest";
+
+const client = new Mistral({ apiKey: apiKey });
+
+const messages = [
+ { role: "user", content: "What's the status of my transaction?" },
+];
+
+let stream = await client.chat.stream({
+ model: model,
+ messages: messages,
+ tools: tools,
+});
+
+let full_content = "";
+for await (const event of stream) {
+ const content = event.data?.choices[0]?.delta.content;
+ if (!content) {
+ continue;
+ }
+
+ full_content += content;
+
+ process.stdout.write(content);
+}
+messages.push({
+ role: "assistant",
+ content: full_content,
+});
+
+messages.push({ role: "user", content: "My transaction ID is T1001." });
+
+stream = await client.chat.stream({
+ model: model,
+ messages: messages,
+ tools: tools,
+});
+
+let full_tool_call: ToolCall[] = [];
+
+for await (const event of stream) {
+
+ const toolCalls = event.data?.choices[0]?.delta.toolCalls;
+ if (!toolCalls) {
+ continue;
+ }
+ full_tool_call = toolCalls;
+}
+
+messages.push({
+ role: "assistant",
+ toolCalls: full_tool_call,
+});
+
+const toolCalls = full_tool_call;
+for (const toolCall of toolCalls) {
+ const functionName = toolCall.function.name;
+ const functionParams = JSON.parse(toolCall.function.arguments);
+
+ console.log(`calling functionName: ${functionName}`);
+ console.log(`functionParams: ${toolCall.function.arguments}`);
+ const functionResult = namesToFunctions[functionName](functionParams);
+
+ messages.push({
+ role: "tool",
+ name: functionName,
+ content: functionResult,
+ tool_call_id: toolCall.id,
+ });
+}
+console.log(messages);
+console.log(tools);
+
+stream = await client.chat.stream({
+ model: model,
+ messages: messages,
+ tools: tools,
+});
+
+for await (const event of stream) {
+ const content = event.data?.choices[0]?.delta.content;
+ if (!content) {
+ continue;
+ }
+
+ process.stdout.write(content);
+}
+console.log("\ndone")
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_jobs.ts b/node_modules/@mistralai/mistralai/examples/src/async_jobs.ts
new file mode 100644
index 0000000000..4c9003fcab
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_jobs.ts
@@ -0,0 +1,42 @@
+import * as fs from "fs";
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const mistral = new Mistral();
+
+// Create a new file
+const blob = new Blob([fs.readFileSync("src/file.jsonl")], {
+ type: "application/json",
+});
+const createdFile = await mistral.files.upload({ file: blob });
+
+// Create a new job
+const hyperparameters = {
+ training_steps: 10,
+ learning_rate: 0.0001,
+};
+const createdJob = await mistral.fineTuning.jobs.create({
+ model: "open-mistral-7b",
+ trainingFiles: [{ fileId: createdFile.id, weight: 1 }],
+ validationFiles: [createdFile.id],
+ hyperparameters: hyperparameters,
+});
+console.log(createdJob);
+
+// List jobs
+const jobs = await mistral.fineTuning.jobs.list();
+console.log(jobs);
+
+// Retrieve a job
+const retrievedJob = await mistral.fineTuning.jobs.get({ jobId: createdJob.id });
+console.log(retrievedJob);
+
+// Cancel a job
+const canceledJob = await mistral.fineTuning.jobs.cancel({
+ jobId: createdJob.id,
+});
+console.log(canceledJob);
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_json_format.ts b/node_modules/@mistralai/mistralai/examples/src/async_json_format.ts
new file mode 100644
index 0000000000..be467457c7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_json_format.ts
@@ -0,0 +1,16 @@
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const mistral = new Mistral({ apiKey: apiKey });
+
+const chatResponse = await mistral.chat.complete({
+ model: "mistral-large-latest",
+ messages: [{ role: "user", content: "What is the best French cheese?" }],
+ responseFormat: { type: "json_object" },
+});
+
+console.log("Chat:", chatResponse.choices[0].message.content);
diff --git a/node_modules/@mistralai/mistralai/examples/src/async_list_models.ts b/node_modules/@mistralai/mistralai/examples/src/async_list_models.ts
new file mode 100644
index 0000000000..683a891784
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/async_list_models.ts
@@ -0,0 +1,14 @@
+import { Mistral } from "@mistralai/mistralai";
+
+const apiKey = process.env["MISTRAL_API_KEY"];
+if (!apiKey) {
+ throw new Error("missing MISTRAL_API_KEY environment variable");
+}
+
+const mistral = new Mistral({ apiKey: apiKey });
+
+const listModelsResponse = await mistral.models.list();
+
+listModelsResponse.data.forEach((model) => {
+ console.log("Model:", model);
+});
diff --git a/node_modules/@mistralai/mistralai/examples/src/azure/async_chat_no_streaming.ts b/node_modules/@mistralai/mistralai/examples/src/azure/async_chat_no_streaming.ts
new file mode 100644
index 0000000000..89a1978717
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/azure/async_chat_no_streaming.ts
@@ -0,0 +1,27 @@
+import { MistralAzure } from "@mistralai/mistralai-azure";
+
+const azureAPIKey = process.env["AZURE_API_KEY"];
+if (!azureAPIKey) {
+ throw new Error("missing AZURE_API_KEY environment variable");
+}
+
+const azureEndpoint = process.env["AZURE_ENDPOINT"];
+if (!azureEndpoint) {
+ throw new Error("missing AZURE_ENDPOINT environment variable");
+}
+
+const sdk = new MistralAzure({
+ apiKey: azureAPIKey,
+ endpoint: azureEndpoint,
+});
+
+const chatResult = await sdk.chat.complete({
+ messages: [
+ {
+ role: "user",
+ content: "What is the best French cheese ?",
+ },
+ ],
+});
+
+console.log("Success", chatResult);
diff --git a/node_modules/@mistralai/mistralai/examples/src/gcp/async_chat_no_streaming.ts b/node_modules/@mistralai/mistralai/examples/src/gcp/async_chat_no_streaming.ts
new file mode 100644
index 0000000000..cd4d05fffc
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/src/gcp/async_chat_no_streaming.ts
@@ -0,0 +1,23 @@
+import { MistralGoogleCloud } from "@mistralai/mistralai-gcp";
+
+const projectId = process.env["GOOGLE_PROJECT_ID"];
+if (!projectId) {
+ throw new Error("missing GOOGLE_PROJECT_ID environment variable");
+}
+
+const sdk = new MistralGoogleCloud({
+ region: "europe-west4",
+ projectId: projectId,
+});
+
+const chatResult = await sdk.chat.complete({
+ model: "mistral-large-2407",
+ messages: [
+ {
+ role: "user",
+ content: "What is the best French cheese ?",
+ },
+ ],
+});
+
+console.log("Success", chatResult);
diff --git a/node_modules/@mistralai/mistralai/examples/test.ts b/node_modules/@mistralai/mistralai/examples/test.ts
new file mode 100644
index 0000000000..335758b7c2
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/examples/test.ts
@@ -0,0 +1,35 @@
+import { execSync } from "node:child_process";
+import { globSync } from "glob";
+
+type Result = {
+ file: string;
+ success: boolean;
+};
+
+const results: Result[] = [];
+
+const files = globSync("src/**/*.ts");
+for (const file of files) {
+ try {
+ execSync(`npm run script -- ${file}`, { stdio: "inherit" });
+ results.push({ file, success: true });
+ } catch (error) {
+ results.push({ file, success: false });
+ }
+}
+
+const failedCount = results.filter((x) => !x.success).length;
+
+if (failedCount > 0) {
+ console.log(`❌ ${failedCount}/${results.length} examples failed to run:`);
+} else {
+ console.log(`🎉 All examples ran successfully!`);
+}
+
+for (const result of results) {
+ console.log(` - ${result.success ? "✅" : "❌"} ${result.file}`);
+}
+
+if (failedCount > 0) {
+ process.exit(1);
+}
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsComplete.d.ts b/node_modules/@mistralai/mistralai/funcs/agentsComplete.d.ts
new file mode 100644
index 0000000000..8c687dd880
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsComplete.d.ts
@@ -0,0 +1,13 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Agents Completion
+ */
+export declare function agentsComplete(client$: MistralCore, request: components.AgentsCompletionRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=agentsComplete.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsComplete.d.ts.map b/node_modules/@mistralai/mistralai/funcs/agentsComplete.d.ts.map
new file mode 100644
index 0000000000..bba0dc3777
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsComplete.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentsComplete.d.ts","sourceRoot":"","sources":["../src/funcs/agentsComplete.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;GAEG;AACH,wBAAsB,cAAc,CAClC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,uBAAuB,EAC3C,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,sBAAsB,EAC/B,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA+EA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsComplete.js b/node_modules/@mistralai/mistralai/funcs/agentsComplete.js
new file mode 100644
index 0000000000..f424109bc9
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsComplete.js
@@ -0,0 +1,93 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.agentsComplete = agentsComplete;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Agents Completion
+ */
+async function agentsComplete(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.AgentsCompletionRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/agents/completions")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "agents_completion_v1_agents_completions_post",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, components.ChatCompletionResponse$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=agentsComplete.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsComplete.js.map b/node_modules/@mistralai/mistralai/funcs/agentsComplete.js.map
new file mode 100644
index 0000000000..46b05b409b
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsCom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AE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE;KACpD,CAAC;IAEF,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAW9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,oCAAoC,CAAC,EAC7D,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,MAAM,CAAC,iCAAiC,CAAC,EACzD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,EAAE,EAAE,WAAW,EAAE,eAAe,EAAE,CAAC,CAAC;IAC9C,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsStream.d.ts b/node_modules/@mistralai/mistralai/funcs/agentsStream.d.ts
new file mode 100644
index 0000000000..15d96c3790
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsStream.d.ts
@@ -0,0 +1,17 @@
+import { MistralCore } from "../core.js";
+import { EventStream } from "../lib/event-streams.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Stream Agents completion
+ *
+ * @remarks
+ * Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+export declare function agentsStream(client$: MistralCore, request: components.AgentsCompletionStreamRequest, options?: RequestOptions): Promise, errors.HTTPValidationError | SDKError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
+//# sourceMappingURL=agentsStream.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsStream.d.ts.map b/node_modules/@mistralai/mistralai/funcs/agentsStream.d.ts.map
new file mode 100644
index 0000000000..c16b396d0c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsStream.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentsStream.d.ts","sourceRoot":"","sources":["../src/funcs/agentsStream.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGtD,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,YAAY,CAChC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,6BAA6B,EACjD,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,WAAW,CAAC,UAAU,CAAC,eAAe,CAAC,EACrC,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA4FA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsStream.js b/node_modules/@mistralai/mistralai/funcs/agentsStream.js
new file mode 100644
index 0000000000..f2433a5d45
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsStream.js
@@ -0,0 +1,106 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.agentsStream = agentsStream;
+const z = __importStar(require("zod"));
+const encodings_js_1 = require("../lib/encodings.js");
+const event_streams_js_1 = require("../lib/event-streams.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Stream Agents completion
+ *
+ * @remarks
+ * Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+async function agentsStream(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.AgentsCompletionStreamRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/agents/completions#stream")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "text/event-stream",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "stream_agents",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.sse(200, z.instanceof((ReadableStream)).transform(stream => {
+ return new event_streams_js_1.EventStream({
+ stream,
+ decoder(rawEvent) {
+ const schema = components.CompletionEvent$inboundSchema;
+ return schema.parse(rawEvent);
+ },
+ });
+ }), { sseSentinel: "[DONE]" }), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=agentsStream.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/agentsStream.js.map b/node_modules/@mistralai/mistralai/funcs/agentsStream.js.map
new file mode 100644
index 0000000000..473b198271
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/agentsStream.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentsStream.js","sourceRoot":"","sources":["../src/funcs/agentsStream.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA8BH,oCA4GC;AAxID,uCAAyB;AAEzB,sDAAgE;AAChE,8DAAsD;AACtD,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ5D,kEAAoD;AAKpD;;;;;GAKG;AACI,KAAK,UAAU,YAAY,CAChC,OAAoB,EACpB,OAAiD,EACjD,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,4CAA4C,CAAC,KAAK,CAAC,MAAM,CAAC,EACvE,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAA,yBAAW,EAAC,MAAM,EAAE,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;IAE/D,MAAM,KAAK,GAAG,IAAA,mBAAU,EAAC,+BAA+B,CAAC,EAAE,CAAC;IAE5D,MAAM,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.d.ts b/node_modules/@mistralai/mistralai/funcs/chatComplete.d.ts
new file mode 100644
index 0000000000..71b93b3620
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatComplete.d.ts
@@ -0,0 +1,13 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Chat Completion
+ */
+export declare function chatComplete(client$: MistralCore, request: components.ChatCompletionRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=chatComplete.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatComplete.d.ts.map b/node_modules/@mistralai/mistralai/funcs/chatComplete.d.ts.map
new file mode 100644
index 0000000000..7691f49338
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatComplete.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatComplete.d.ts","sourceRoot":"","sources":["../src/funcs/chatComplete.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;GAEG;AACH,wBAAsB,YAAY,CAChC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,qBAAqB,EACzC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,sBAAsB,EAC/B,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA+EA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatComplete.js b/node_modules/@mistralai/mistralai/funcs/chatComplete.js
new file mode 100644
index 0000000000..5fb7ccc6c8
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatComplete.js
@@ -0,0 +1,93 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.chatComplete = chatComplete;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Chat Completion
+ */
+async function chatComplete(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.ChatCompletionRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/chat/completions")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "chat_completion_v1_chat_completions_post",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, components.ChatCompletionResponse$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=chatComplete.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatComplete.js.map b/node_modules/@mistralai/mistralai/funcs/chatComplete.js.map
new file mode 100644
index 0000000000..14e2bc37c3
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatComplete.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatComplete.js","sourceRoot":"","sources":["../src/funcs/chatComplete.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AAyBH,oCA+FC;AArHD,sDAAgE;AAChE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ5D,kEAAoD;AAKpD;;GAEG;AACI,KAAK,UAAU,YAAY,CAChC,OAAoB,EACpB,OAAyC,EACzC,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CAAC,UAAU,CAAC,oCAAoC,CAAC,KAAK,CAAC,MAAM,CAAC,EACzE,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAA,yBAAW,EAAC,MAAM,EAAE,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;IAE/D,MAAM,KAAK,GAAG,IAAA,mBAAU,EAAC,sBAAsB,CAAC,EAAE,CAAC;IAEnD,MAAM,QAAQ,GAAG,IAAI,OAAO,CAAC;QAC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P,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,eAAe,GAAG;QACtB,QAAQ,EAAE,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE;KACpD,CAAC;IAEF,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAW9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,oCAAoC,CAAC,EAC7D,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,MAAM,CAAC,iCAAiC,CAAC,EACzD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,EAAE,EAAE,WAAW,EAAE,eAAe,EAAE,CAAC,CAAC;IAC9C,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatStream.d.ts b/node_modules/@mistralai/mistralai/funcs/chatStream.d.ts
new file mode 100644
index 0000000000..edb6dca5dc
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatStream.d.ts
@@ -0,0 +1,17 @@
+import { MistralCore } from "../core.js";
+import { EventStream } from "../lib/event-streams.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Stream chat completion
+ *
+ * @remarks
+ * Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+export declare function chatStream(client$: MistralCore, request: components.ChatCompletionStreamRequest, options?: RequestOptions): Promise, errors.HTTPValidationError | SDKError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
+//# sourceMappingURL=chatStream.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatStream.d.ts.map b/node_modules/@mistralai/mistralai/funcs/chatStream.d.ts.map
new file mode 100644
index 0000000000..1bea3fcb47
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatStream.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatStream.d.ts","sourceRoot":"","sources":["../src/funcs/chatStream.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGtD,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,UAAU,CAC9B,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,2BAA2B,EAC/C,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,WAAW,CAAC,UAAU,CAAC,eAAe,CAAC,EACrC,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA4FA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatStream.js b/node_modules/@mistralai/mistralai/funcs/chatStream.js
new file mode 100644
index 0000000000..e6c2957e0c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatStream.js
@@ -0,0 +1,106 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.chatStream = chatStream;
+const z = __importStar(require("zod"));
+const encodings_js_1 = require("../lib/encodings.js");
+const event_streams_js_1 = require("../lib/event-streams.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Stream chat completion
+ *
+ * @remarks
+ * Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+async function chatStream(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.ChatCompletionStreamRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/chat/completions#stream")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "text/event-stream",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "stream_chat",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.sse(200, z.instanceof((ReadableStream)).transform(stream => {
+ return new event_streams_js_1.EventStream({
+ stream,
+ decoder(rawEvent) {
+ const schema = components.CompletionEvent$inboundSchema;
+ return schema.parse(rawEvent);
+ },
+ });
+ }), { sseSentinel: "[DONE]" }), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=chatStream.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/chatStream.js.map b/node_modules/@mistralai/mistralai/funcs/chatStream.js.map
new file mode 100644
index 0000000000..4712694d74
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/chatStream.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatStream.js","sourceRoot":"","sources":["../src/funcs/chatStream.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA8BH,gCA4GC;AAxID,uCAAyB;AAEzB,sDAAgE;AAChE,8DAAsD;AACtD,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ5D,kEAAoD;AAKpD;;;;;GAKG;AACI,KAAK,UAAU,UAAU,CAC9B,OAAoB,EACpB,OAA+C,EAC/C,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,0CAA0C,CAAC,KAAK,CAAC,MAAM,CAAC,EACrE,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,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AAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,EAAE,EAAE,WAAW,EAAE,eAAe,EAAE,CAAC,CAAC;IAC9C,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.d.ts b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.d.ts
new file mode 100644
index 0000000000..4d9541caed
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Embeddings
+ *
+ * @remarks
+ * Embeddings
+ */
+export declare function embeddingsCreate(client$: MistralCore, request: components.EmbeddingRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=embeddingsCreate.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.d.ts.map b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.d.ts.map
new file mode 100644
index 0000000000..aed3ce709c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"embeddingsCreate.d.ts","sourceRoot":"","sources":["../src/funcs/embeddingsCreate.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,gBAAgB,CACpC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,gBAAgB,EACpC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,iBAAiB,EAC1B,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA+EA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.js b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.js
new file mode 100644
index 0000000000..5fea6afb2a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.js
@@ -0,0 +1,96 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.embeddingsCreate = embeddingsCreate;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Embeddings
+ *
+ * @remarks
+ * Embeddings
+ */
+async function embeddingsCreate(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.EmbeddingRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/embeddings")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "embeddings_v1_embeddings_post",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, components.EmbeddingResponse$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=embeddingsCreate.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.js.map b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.js.map
new file mode 100644
index 0000000000..666b8533cb
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/embeddingsCreate.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"embeddingsCreate.js","sourceRoot":"","sources":["../src/funcs/embeddingsCreate.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,4CA+FC;AAxHD,sDAAgE;AAChE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ5D,kEAAoD;AAKpD;;;;;GAKG;AACI,KAAK,UAAU,gBAAgB,CACpC,OAAoB,EACpB,OAAoC,EACpC,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CAAC,UAAU,CAAC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OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesDelete.d.ts b/node_modules/@mistralai/mistralai/funcs/filesDelete.d.ts
new file mode 100644
index 0000000000..d2e190885e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesDelete.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Delete File
+ *
+ * @remarks
+ * Delete a file.
+ */
+export declare function filesDelete(client$: MistralCore, request: operations.FilesApiRoutesDeleteFileRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=filesDelete.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesDelete.d.ts.map b/node_modules/@mistralai/mistralai/funcs/filesDelete.d.ts.map
new file mode 100644
index 0000000000..a3d6901ac8
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesDelete.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesDelete.d.ts","sourceRoot":"","sources":["../src/funcs/filesDelete.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,+BAA+B,EACnD,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,aAAa,EACtB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAgFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesDelete.js b/node_modules/@mistralai/mistralai/funcs/filesDelete.js
new file mode 100644
index 0000000000..4343090cde
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesDelete.js
@@ -0,0 +1,98 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.filesDelete = filesDelete;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Delete File
+ *
+ * @remarks
+ * Delete a file.
+ */
+async function filesDelete(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.FilesApiRoutesDeleteFileRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ file_id: (0, encodings_js_1.encodeSimple)("file_id", payload$.file_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/files/{file_id}")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "files_api_routes_delete_file",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "DELETE",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.DeleteFileOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=filesDelete.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesDelete.js.map b/node_modules/@mistralai/mistralai/funcs/filesDelete.js.map
new file mode 100644
index 0000000000..2131394b98
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesDelete.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesDelete.js","sourceRoot":"","sources":["../src/funcs/filesDelete.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,kCA+FC;AAxHD,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,WAAW,CAC/B,OAAoB,EACpB,OAAmD,EACnD,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,8CAA8C,CAAC,KAAK,CAAC,MAAM,CAAC,EACzE,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAI,CAAC;IAEnB,MAAM,WAAW,GAAG;QAClB,OAAO,EAAE,IAAA,2BAAa,EAAC,SAAS,EAAE,QAAQ,CAAC,OAAO,EAAE;YAClD,OAAO,EAAE,KAAK;YACd,Y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1B,WAAW,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO;eACxB,OAAO,CAAC,QAAQ,CAAC,WAAW;QACjC,UAAU,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,2BAA2B,CAAC,EACpD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesList.d.ts b/node_modules/@mistralai/mistralai/funcs/filesList.d.ts
new file mode 100644
index 0000000000..c0553ee1e0
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesList.d.ts
@@ -0,0 +1,15 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * List Files
+ *
+ * @remarks
+ * Returns a list of files that belong to the user's organization.
+ */
+export declare function filesList(client$: MistralCore, options?: RequestOptions): Promise>;
+//# sourceMappingURL=filesList.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesList.d.ts.map b/node_modules/@mistralai/mistralai/funcs/filesList.d.ts.map
new file mode 100644
index 0000000000..edc7baa853
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesList.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesList.d.ts","sourceRoot":"","sources":["../src/funcs/filesList.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,SAAS,CAC7B,OAAO,EAAE,WAAW,EACpB,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,YAAY,EACrB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA0DA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesList.js b/node_modules/@mistralai/mistralai/funcs/filesList.js
new file mode 100644
index 0000000000..2959272d0d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesList.js
@@ -0,0 +1,81 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.filesList = filesList;
+const m$ = __importStar(require("../lib/matchers.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+/**
+ * List Files
+ *
+ * @remarks
+ * Returns a list of files that belong to the user's organization.
+ */
+async function filesList(client$, options) {
+ const path$ = (0, url_js_1.pathToFunc)("/v1/files")();
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "files_api_routes_list_files",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "GET",
+ path: path$,
+ headers: headers$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.ListFilesOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=filesList.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesList.js.map b/node_modules/@mistralai/mistralai/funcs/filesList.js.map
new file mode 100644
index 0000000000..a4ccfd103d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesList.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesList.js","sourceRoot":"","sources":["../src/funcs/filesList.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AAyBH,8BAwEC;AA9FD,uDAAyC;AAEzC,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAY5D;;;;;GAKG;AACI,KAAK,UAAU,SAAS,CAC7B,OAAoB,EACpB,OAAwB;IAaxB,MAAM,KAAK,GAAG,IAAA,mBAAU,EAAC,WAAW,CAAC,EAAE,CAAC;IAExC,MAAM,QAAQ,GAAG,IAAI,OAAO,CAAC;QAC3B,MAAM,EAAE,kBAAkB;KAC3B,CAAC,CAAC;IAEH,MAAM,OAAO,GAAG,MAAM,IAAA,6BAAe,EAAC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC/D,MAAM,SAAS,GAAG,OAAO,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC;IAC7D,MAAM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AAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,0BAA0B,CAAC,EACnD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesRetrieve.d.ts b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.d.ts
new file mode 100644
index 0000000000..2b6ff7e8a8
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Retrieve File
+ *
+ * @remarks
+ * Returns information about a specific file.
+ */
+export declare function filesRetrieve(client$: MistralCore, request: operations.FilesApiRoutesRetrieveFileRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=filesRetrieve.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesRetrieve.d.ts.map b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.d.ts.map
new file mode 100644
index 0000000000..cb9db7fd85
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesRetrieve.d.ts","sourceRoot":"","sources":["../src/funcs/filesRetrieve.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,iCAAiC,EACrD,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,eAAe,EACxB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAgFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesRetrieve.js b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.js
new file mode 100644
index 0000000000..4a0ad65508
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.js
@@ -0,0 +1,98 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.filesRetrieve = filesRetrieve;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Retrieve File
+ *
+ * @remarks
+ * Returns information about a specific file.
+ */
+async function filesRetrieve(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.FilesApiRoutesRetrieveFileRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ file_id: (0, encodings_js_1.encodeSimple)("file_id", payload$.file_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/files/{file_id}")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "files_api_routes_retrieve_file",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "GET",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.RetrieveFileOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=filesRetrieve.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesRetrieve.js.map b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.js.map
new file mode 100644
index 0000000000..3c5f5beb19
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesRetrieve.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesRetrieve.js","sourceRoot":"","sources":["../src/funcs/filesRetrieve.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,sCA+FC;AAxHD,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,aAAa,CACjC,OAAoB,EACpB,OAAqD,EACrD,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,gDAAgD,CAAC,KAAK,CAAC,MAAM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QAAQ,CAAC,SAAS,IAAI,CAAC,CAAC;KAClE,EAAE,OAAO,CAAC,CAAC;IACZ,IAAI,CAAC,UAAU,CAAC,EAAE,EAAE,CAAC;QACnB,OAAO,UAAU,CAAC;IACpB,CAAC;IACD,MAAM,QAAQ,GAAG,UAAU,CAAC,KAAK,CAAC;IAElC,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAE;QAC3C,OAAO;QACP,UAAU,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC;QAC1B,WAAW,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO;eACxB,OAAO,CAAC,QAAQ,CAAC,WAAW;QACjC,UAAU,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,6BAA6B,CAAC,EACtD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesUpload.d.ts b/node_modules/@mistralai/mistralai/funcs/filesUpload.d.ts
new file mode 100644
index 0000000000..da13efdd2d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesUpload.d.ts
@@ -0,0 +1,20 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Upload File
+ *
+ * @remarks
+ * Upload a file that can be used across various endpoints.
+ *
+ * The size of individual files can be a maximum of 512 MB. The Fine-tuning API only supports .jsonl files.
+ *
+ * Please contact us if you need to increase these storage limits.
+ */
+export declare function filesUpload(client$: MistralCore, request: operations.FilesApiRoutesUploadFileMultiPartBodyParams, options?: RequestOptions): Promise>;
+//# sourceMappingURL=filesUpload.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesUpload.d.ts.map b/node_modules/@mistralai/mistralai/funcs/filesUpload.d.ts.map
new file mode 100644
index 0000000000..12572f347a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesUpload.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesUpload.d.ts","sourceRoot":"","sources":["../src/funcs/filesUpload.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAE5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAGxC;;;;;;;;;GASG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,2CAA2C,EAC/D,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,aAAa,EACtB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA2FA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesUpload.js b/node_modules/@mistralai/mistralai/funcs/filesUpload.js
new file mode 100644
index 0000000000..f3c0fdfcd4
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesUpload.js
@@ -0,0 +1,113 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.filesUpload = filesUpload;
+const files_js_1 = require("../lib/files.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+const blobs_js_1 = require("../types/blobs.js");
+const streams_js_1 = require("../types/streams.js");
+/**
+ * Upload File
+ *
+ * @remarks
+ * Upload a file that can be used across various endpoints.
+ *
+ * The size of individual files can be a maximum of 512 MB. The Fine-tuning API only supports .jsonl files.
+ *
+ * Please contact us if you need to increase these storage limits.
+ */
+async function filesUpload(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.FilesApiRoutesUploadFileMultiPartBodyParams$outboundSchema
+ .parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = new FormData();
+ if ((0, blobs_js_1.isBlobLike)(payload$.file)) {
+ body$.append("file", payload$.file);
+ }
+ else if ((0, streams_js_1.isReadableStream)(payload$.file.content)) {
+ const buffer = await (0, files_js_1.readableStreamToArrayBuffer)(payload$.file.content);
+ const blob = new Blob([buffer], { type: "application/octet-stream" });
+ body$.append("file", blob);
+ }
+ else {
+ body$.append("file", new Blob([payload$.file.content], { type: "application/octet-stream" }), payload$.file.fileName);
+ }
+ if (payload$.purpose !== undefined) {
+ body$.append("purpose", payload$.purpose);
+ }
+ const path$ = (0, url_js_1.pathToFunc)("/v1/files")();
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "files_api_routes_upload_file",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.UploadFileOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=filesUpload.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/filesUpload.js.map b/node_modules/@mistralai/mistralai/funcs/filesUpload.js.map
new file mode 100644
index 0000000000..3466f3809c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/filesUpload.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"filesUpload.js","sourceRoot":"","sources":["../src/funcs/filesUpload.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AAkCH,kCA0GC;AAzID,8CAA8D;AAC9D,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAC5D,gDAA+C;AAE/C,oDAAuD;AAEvD;;;;;;;;;GASG;AACI,KAAK,UAAU,WAAW,CAC/B,OAAoB,EACpB,OAA+D,EAC/D,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,0DAA0D;SAClE,KAAK,CA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AE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,2BAA2B,CAAC,EACpD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimComplete.d.ts b/node_modules/@mistralai/mistralai/funcs/fimComplete.d.ts
new file mode 100644
index 0000000000..d55e52fc2a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimComplete.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Fim Completion
+ *
+ * @remarks
+ * FIM completion.
+ */
+export declare function fimComplete(client$: MistralCore, request: components.FIMCompletionRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=fimComplete.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimComplete.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fimComplete.d.ts.map
new file mode 100644
index 0000000000..7ce227b909
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimComplete.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fimComplete.d.ts","sourceRoot":"","sources":["../src/funcs/fimComplete.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,oBAAoB,EACxC,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,qBAAqB,EAC9B,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA+EA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimComplete.js b/node_modules/@mistralai/mistralai/funcs/fimComplete.js
new file mode 100644
index 0000000000..2003d02229
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimComplete.js
@@ -0,0 +1,96 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fimComplete = fimComplete;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Fim Completion
+ *
+ * @remarks
+ * FIM completion.
+ */
+async function fimComplete(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.FIMCompletionRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fim/completions")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "fim_completion_v1_fim_completions_post",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, components.FIMCompletionResponse$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fimComplete.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimComplete.js.map b/node_modules/@mistralai/mistralai/funcs/fimComplete.js.map
new file mode 100644
index 0000000000..1b92f951ae
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimComplete.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fimComplete.js","sourceRoot":"","sources":["../src/funcs/fimComplete.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,kCA+FC;AAxHD,sDAAgE;AAChE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ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AC,EACzD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,EAAE,EAAE,WAAW,EAAE,eAAe,EAAE,CAAC,CAAC;IAC9C,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimStream.d.ts b/node_modules/@mistralai/mistralai/funcs/fimStream.d.ts
new file mode 100644
index 0000000000..d9b5a32016
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimStream.d.ts
@@ -0,0 +1,17 @@
+import { MistralCore } from "../core.js";
+import { EventStream } from "../lib/event-streams.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Stream fim completion
+ *
+ * @remarks
+ * Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+export declare function fimStream(client$: MistralCore, request: components.FIMCompletionStreamRequest, options?: RequestOptions): Promise, errors.HTTPValidationError | SDKError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
+//# sourceMappingURL=fimStream.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimStream.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fimStream.d.ts.map
new file mode 100644
index 0000000000..ef2fc58374
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimStream.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fimStream.d.ts","sourceRoot":"","sources":["../src/funcs/fimStream.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAGtD,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,SAAS,CAC7B,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,0BAA0B,EAC9C,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,WAAW,CAAC,UAAU,CAAC,eAAe,CAAC,EACrC,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA4FA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimStream.js b/node_modules/@mistralai/mistralai/funcs/fimStream.js
new file mode 100644
index 0000000000..c2b7525c96
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimStream.js
@@ -0,0 +1,106 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fimStream = fimStream;
+const z = __importStar(require("zod"));
+const encodings_js_1 = require("../lib/encodings.js");
+const event_streams_js_1 = require("../lib/event-streams.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * Stream fim completion
+ *
+ * @remarks
+ * Mistral AI provides the ability to stream responses back to a client in order to allow partial results for certain requests. Tokens will be sent as data-only server-sent events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+async function fimStream(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.FIMCompletionStreamRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fim/completions#stream")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "text/event-stream",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "stream_fim",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.sse(200, z.instanceof((ReadableStream)).transform(stream => {
+ return new event_streams_js_1.EventStream({
+ stream,
+ decoder(rawEvent) {
+ const schema = components.CompletionEvent$inboundSchema;
+ return schema.parse(rawEvent);
+ },
+ });
+ }), { sseSentinel: "[DONE]" }), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fimStream.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fimStream.js.map b/node_modules/@mistralai/mistralai/funcs/fimStream.js.map
new file mode 100644
index 0000000000..cf0498d9bf
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fimStream.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fimStream.js","sourceRoot":"","sources":["../src/funcs/fimStream.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA8BH,8BA4GC;AAxID,uCAAyB;AAEzB,sDAAgE;AAChE,8DAAsD;AACtD,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ5D,kEAAoD;AAKpD;;;;;GAKG;AACI,KAAK,UAAU,SAAS,CAC7B,OAAoB,EACpB,OAA8C,EAC9C,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,yCAAyC,CAAC,KAAK,CAAC,MAAM,CAAC,EACpE,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAA,yBAAW,EAAC,MAAM,EAAE,QAAQ,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;IAE/D,MAAM,KAAK,GAAG,IAAA,mBAAU,EAAC,4BAA4B,CAAC,EAAE,CAAC;IAEzD,MAAM,QAAQ,GAAG,IAAI,OAAO,CAAC;QAC3B,cAAc,EAAE,kBAAkB;QAClC,MAAM,EAAE,mBAAmB;KAC5B,CAAC,CAAC;IAEH,MAAM,OAAO,GAAG,MAAM,IAAA,6BAAe,EAAC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC/D,MAAM,SAAS,GAAG,OAAO,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,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,CAAC,KAAK,CAAC;IAEhC,MAAM,eAAe,GAAG;QACtB,QAAQ,EAAE,EAAE,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE;KACpD,CAAC;IAEF,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAW9B,EAAE,CAAC,GAAG,CACJ,GAAG,EACH,CAAC,CAAC,UAAU,CAAC,CAAA,cAA0B,CAAA,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,EAAE;QAC1D,OAAO,IAAI,8BAAW,CAAC;YACrB,MAAM;YACN,OAAO,CAAC,QAAQ;gBACd,MAAM,MAAM,GAAG,UAAU,CAAC,6BAA6B,CAAC;gBACxD,OAAO,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;YAChC,CAAC;SACF,CAAC,CAAC;IACL,CAAC,CAAC,EACF,EAAE,WAAW,EAAE,QAAQ,EAAE,CAC1B,EACD,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,MAAM,CAAC,iCAAiC,CAAC,EACzD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,EAAE,EAAE,WAAW,EAAE,eAAe,EAAE,CAAC,CAAC;IAC9C,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.d.ts b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.d.ts
new file mode 100644
index 0000000000..f9956f74ac
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Cancel Fine Tuning Job
+ *
+ * @remarks
+ * Request the cancellation of a fine tuning job.
+ */
+export declare function fineTuningJobsCancel(client$: MistralCore, request: operations.JobsApiRoutesFineTuningCancelFineTuningJobRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=fineTuningJobsCancel.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.d.ts.map
new file mode 100644
index 0000000000..7c52162dee
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsCancel.d.ts","sourceRoot":"","sources":["../src/funcs/fineTuningJobsCancel.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,oBAAoB,CACxC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,iDAAiD,EACrE,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,cAAc,EACvB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAmFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.js b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.js
new file mode 100644
index 0000000000..ca864db3b7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.js
@@ -0,0 +1,99 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fineTuningJobsCancel = fineTuningJobsCancel;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Cancel Fine Tuning Job
+ *
+ * @remarks
+ * Request the cancellation of a fine tuning job.
+ */
+async function fineTuningJobsCancel(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations
+ .JobsApiRoutesFineTuningCancelFineTuningJobRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ job_id: (0, encodings_js_1.encodeSimple)("job_id", payload$.job_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/jobs/{job_id}/cancel")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_cancel_fine_tuning_job",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.DetailedJobOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fineTuningJobsCancel.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.js.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.js.map
new file mode 100644
index 0000000000..57ebd8d83d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCancel.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsCancel.js","sourceRoot":"","sources":["../src/funcs/fineTuningJobsCancel.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,oDAkGC;AA3HD,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,oBAAoB,CACxC,OAAoB,EACpB,OAAqE,EACrE,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU;SACP,gEAAgE,CAAC,KAAK,CACrE,MAAM,CACP,EACL,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAI,CAAC;IAEnB,MAAM,WAAW,GAAG;QAClB,MAAM,EAAE,IAAA,2BAAa,EAAC,QAAQ,EAAE,QAAQ,CAAC,MAAM,EAAE;YAC/C,OAAO,EAAE,KAAK;YACd,YAAY,EAAE,SAAS;SACxB,CAAC;KACH,CAAC;IAEF,MAAM,KAAK,GAAG,IAAA,mBAAU,E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,QAAQ,CAAC,WAAW;QACjC,UAAU,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,4BAA4B,CAAC,EACrD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.d.ts b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.d.ts
new file mode 100644
index 0000000000..e19b76bcea
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Create Fine Tuning Job
+ *
+ * @remarks
+ * Create a new fine-tuning job, it will be queued for processing.
+ */
+export declare function fineTuningJobsCreate(client$: MistralCore, request: components.JobIn, options?: RequestOptions): Promise>;
+//# sourceMappingURL=fineTuningJobsCreate.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.d.ts.map
new file mode 100644
index 0000000000..1ccb3d1628
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsCreate.d.ts","sourceRoot":"","sources":["../src/funcs/fineTuningJobsCreate.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,oBAAoB,CACxC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,KAAK,EACzB,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,kDAAkD,EAC3D,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA6EA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.js b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.js
new file mode 100644
index 0000000000..ef7417b98f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.js
@@ -0,0 +1,94 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fineTuningJobsCreate = fineTuningJobsCreate;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Create Fine Tuning Job
+ *
+ * @remarks
+ * Create a new fine-tuning job, it will be queued for processing.
+ */
+async function fineTuningJobsCreate(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => components.JobIn$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$, { explode: true });
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/jobs")();
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_create_fine_tuning_job",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, operations
+ .JobsApiRoutesFineTuningCreateFineTuningJobResponse$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fineTuningJobsCreate.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.js.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.js.map
new file mode 100644
index 0000000000..803738cb45
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsCreate.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsC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U;SACP,gEAAgE,CACpE,EACD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.d.ts b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.d.ts
new file mode 100644
index 0000000000..2ec6a21f14
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Get Fine Tuning Job
+ *
+ * @remarks
+ * Get a fine-tuned job details by its UUID.
+ */
+export declare function fineTuningJobsGet(client$: MistralCore, request: operations.JobsApiRoutesFineTuningGetFineTuningJobRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=fineTuningJobsGet.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.d.ts.map
new file mode 100644
index 0000000000..28806c6b75
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsGet.d.ts","sourceRoot":"","sources":["../src/funcs/fineTuningJobsGet.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,iBAAiB,CACrC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,8CAA8C,EAClE,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,cAAc,EACvB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAiFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.js b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.js
new file mode 100644
index 0000000000..7b22a6d0ab
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.js
@@ -0,0 +1,99 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fineTuningJobsGet = fineTuningJobsGet;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Get Fine Tuning Job
+ *
+ * @remarks
+ * Get a fine-tuned job details by its UUID.
+ */
+async function fineTuningJobsGet(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.JobsApiRoutesFineTuningGetFineTuningJobRequest$outboundSchema
+ .parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ job_id: (0, encodings_js_1.encodeSimple)("job_id", payload$.job_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/jobs/{job_id}")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_get_fine_tuning_job",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "GET",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.DetailedJobOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fineTuningJobsGet.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.js.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.js.map
new file mode 100644
index 0000000000..4afc9b6528
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsGet.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsGet.js","sourceRoot":"","sources":["../src/funcs/fineTuningJobsGet.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,8CAgGC;AAzHD,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,iBAAiB,CACrC,OAAoB,EACpB,OAAkE,EAClE,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,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cs/fineTuningJobsList.d.ts b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.d.ts
new file mode 100644
index 0000000000..550b368968
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Get Fine Tuning Jobs
+ *
+ * @remarks
+ * Get a list of fine-tuning jobs for your organization and user.
+ */
+export declare function fineTuningJobsList(client$: MistralCore, request?: operations.JobsApiRoutesFineTuningGetFineTuningJobsRequest | undefined, options?: RequestOptions): Promise>;
+//# sourceMappingURL=fineTuningJobsList.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.d.ts.map
new file mode 100644
index 0000000000..bfed78856d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsList.d.ts","sourceRoot":"","sources":["../src/funcs/fineTuningJobsList.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,kBAAkB,CACtC,OAAO,EAAE,WAAW,EACpB,OAAO,CAAC,EACJ,UAAU,CAAC,+CAA+C,GAC1D,SAAS,EACb,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,OAAO,EAChB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAuFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.js b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.js
new file mode 100644
index 0000000000..b1f429ae7d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.js
@@ -0,0 +1,105 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fineTuningJobsList = fineTuningJobsList;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Get Fine Tuning Jobs
+ *
+ * @remarks
+ * Get a list of fine-tuning jobs for your organization and user.
+ */
+async function fineTuningJobsList(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.JobsApiRoutesFineTuningGetFineTuningJobsRequest$outboundSchema
+ .optional().parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/jobs")();
+ const query$ = (0, encodings_js_1.encodeFormQuery)({
+ "created_after": payload$ === null || payload$ === void 0 ? void 0 : payload$.created_after,
+ "created_by_me": payload$ === null || payload$ === void 0 ? void 0 : payload$.created_by_me,
+ "model": payload$ === null || payload$ === void 0 ? void 0 : payload$.model,
+ "page": payload$ === null || payload$ === void 0 ? void 0 : payload$.page,
+ "page_size": payload$ === null || payload$ === void 0 ? void 0 : payload$.page_size,
+ "status": payload$ === null || payload$ === void 0 ? void 0 : payload$.status,
+ "suffix": payload$ === null || payload$ === void 0 ? void 0 : payload$.suffix,
+ "wandb_name": payload$ === null || payload$ === void 0 ? void 0 : payload$.wandb_name,
+ "wandb_project": payload$ === null || payload$ === void 0 ? void 0 : payload$.wandb_project,
+ });
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_get_fine_tuning_jobs",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "GET",
+ path: path$,
+ headers: headers$,
+ query: query$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.JobsOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fineTuningJobsList.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.js.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.js.map
new file mode 100644
index 0000000000..e89ce894b2
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsList.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsList.js","sourceRoot":"","sources":["../src/funcs/fineTuningJobsList.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,gDAwGC;AAjID,sDAA0E;AAC1E,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,kBAAkB,CACtC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KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,qBAAqB,CAAC,EAC9C,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.d.ts b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.d.ts
new file mode 100644
index 0000000000..3949e69856
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Start Fine Tuning Job
+ *
+ * @remarks
+ * Request the start of a validated fine tuning job.
+ */
+export declare function fineTuningJobsStart(client$: MistralCore, request: operations.JobsApiRoutesFineTuningStartFineTuningJobRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=fineTuningJobsStart.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.d.ts.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.d.ts.map
new file mode 100644
index 0000000000..9d1b3b32ad
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsStart.d.ts","sourceRoot":"","sources":["../src/funcs/fineTuningJobsStart.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,mBAAmB,CACvC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,gDAAgD,EACpE,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,cAAc,EACvB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAiFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.js b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.js
new file mode 100644
index 0000000000..04bf5fb60e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.js
@@ -0,0 +1,99 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.fineTuningJobsStart = fineTuningJobsStart;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Start Fine Tuning Job
+ *
+ * @remarks
+ * Request the start of a validated fine tuning job.
+ */
+async function fineTuningJobsStart(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.JobsApiRoutesFineTuningStartFineTuningJobRequest$outboundSchema
+ .parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ job_id: (0, encodings_js_1.encodeSimple)("job_id", payload$.job_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/jobs/{job_id}/start")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_start_fine_tuning_job",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.DetailedJobOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=fineTuningJobsStart.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.js.map b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.js.map
new file mode 100644
index 0000000000..3e5a4e6a96
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/fineTuningJobsStart.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"fineTuningJobsStart.js","sourceRoot":"","sources":["../src/funcs/fineTuningJobsStart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,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,4BAA4B,CAAC,EACrD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsArchive.d.ts b/node_modules/@mistralai/mistralai/funcs/modelsArchive.d.ts
new file mode 100644
index 0000000000..601caae73c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsArchive.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Archive Fine Tuned Model
+ *
+ * @remarks
+ * Archive a fine-tuned model.
+ */
+export declare function modelsArchive(client$: MistralCore, request: operations.JobsApiRoutesFineTuningArchiveFineTunedModelRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=modelsArchive.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsArchive.d.ts.map b/node_modules/@mistralai/mistralai/funcs/modelsArchive.d.ts.map
new file mode 100644
index 0000000000..b09b1db40b
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsArchive.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsArchive.d.ts","sourceRoot":"","sources":["../src/funcs/modelsArchive.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,mDAAmD,EACvE,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,iBAAiB,EAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAoFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsArchive.js b/node_modules/@mistralai/mistralai/funcs/modelsArchive.js
new file mode 100644
index 0000000000..03ca346768
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsArchive.js
@@ -0,0 +1,100 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.modelsArchive = modelsArchive;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Archive Fine Tuned Model
+ *
+ * @remarks
+ * Archive a fine-tuned model.
+ */
+async function modelsArchive(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations
+ .JobsApiRoutesFineTuningArchiveFineTunedModelRequest$outboundSchema
+ .parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ model_id: (0, encodings_js_1.encodeSimple)("model_id", payload$.model_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/models/{model_id}/archive")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_archive_fine_tuned_model",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "POST",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.ArchiveFTModelOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=modelsArchive.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsArchive.js.map b/node_modules/@mistralai/mistralai/funcs/modelsArchive.js.map
new file mode 100644
index 0000000000..b646e0cb85
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsArchive.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsArchive.js","sourceRoot":"","sources":["../src/funcs/modelsArchive.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,sCAmGC;AA5HD,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,aAAa,CACjC,OAAoB,EACpB,OAAuE,EACvE,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,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O,uBAAP,OAAO,CAAE,SAAS,KAAI,OAAO,CAAC,QAAQ,CAAC,SAAS,IAAI,CAAC,CAAC;KAClE,EAAE,OAAO,CAAC,CAAC;IACZ,IAAI,CAAC,UAAU,CAAC,EAAE,EAAE,CAAC;QACnB,OAAO,UAAU,CAAC;IACpB,CAAC;IACD,MAAM,QAAQ,GAAG,UAAU,CAAC,KAAK,CAAC;IAElC,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAE;QAC3C,OAAO;QACP,UAAU,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC;QAC1B,WAAW,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO;eACxB,OAAO,CAAC,QAAQ,CAAC,WAAW;QACjC,UAAU,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,+BAA+B,CAAC,EACxD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsDelete.d.ts b/node_modules/@mistralai/mistralai/funcs/modelsDelete.d.ts
new file mode 100644
index 0000000000..611f832a3e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsDelete.d.ts
@@ -0,0 +1,17 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Delete Model
+ *
+ * @remarks
+ * Delete a fine-tuned model.
+ */
+export declare function modelsDelete(client$: MistralCore, request: operations.DeleteModelV1ModelsModelIdDeleteRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=modelsDelete.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsDelete.d.ts.map b/node_modules/@mistralai/mistralai/funcs/modelsDelete.d.ts.map
new file mode 100644
index 0000000000..d8ceb37fb6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsDelete.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsDelete.d.ts","sourceRoot":"","sources":["../src/funcs/modelsDelete.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,YAAY,CAChC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,uCAAuC,EAC3D,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,cAAc,EACvB,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAwFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsDelete.js b/node_modules/@mistralai/mistralai/funcs/modelsDelete.js
new file mode 100644
index 0000000000..3148c33615
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsDelete.js
@@ -0,0 +1,102 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.modelsDelete = modelsDelete;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Delete Model
+ *
+ * @remarks
+ * Delete a fine-tuned model.
+ */
+async function modelsDelete(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.DeleteModelV1ModelsModelIdDeleteRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ model_id: (0, encodings_js_1.encodeSimple)("model_id", payload$.model_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/models/{model_id}")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "delete_model_v1_models__model_id__delete",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "DELETE",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, components.DeleteModelOut$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=modelsDelete.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsDelete.js.map b/node_modules/@mistralai/mistralai/funcs/modelsDelete.js.map
new file mode 100644
index 0000000000..ecdc36ca53
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsDelete.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsDelete.js","sourceRoot":"","sources":["../src/funcs/modelsDelete.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA6BH,oCAwGC;AAlID,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAQ5D,kEAAoD;AAGpD,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,YAAY,CAChC,OAAoB,EACpB,OAA2D,EAC3D,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,sDAAsD,CAAC,KAAK,CACrE,MAAM,CACP,EACH,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAA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d.ts
new file mode 100644
index 0000000000..0e5ae12315
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsList.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * List Models
+ *
+ * @remarks
+ * List all models available to the user.
+ */
+export declare function modelsList(client$: MistralCore, options?: RequestOptions): Promise>;
+//# sourceMappingURL=modelsList.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsList.d.ts.map b/node_modules/@mistralai/mistralai/funcs/modelsList.d.ts.map
new file mode 100644
index 0000000000..b16e7f2fdb
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsList.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsList.d.ts","sourceRoot":"","sources":["../src/funcs/modelsList.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,UAAU,CAC9B,OAAO,EAAE,WAAW,EACpB,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,SAAS,EAClB,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAgEA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsList.js b/node_modules/@mistralai/mistralai/funcs/modelsList.js
new file mode 100644
index 0000000000..9ed6c1570c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsList.js
@@ -0,0 +1,85 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.modelsList = modelsList;
+const m$ = __importStar(require("../lib/matchers.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const errors = __importStar(require("../models/errors/index.js"));
+/**
+ * List Models
+ *
+ * @remarks
+ * List all models available to the user.
+ */
+async function modelsList(client$, options) {
+ const path$ = (0, url_js_1.pathToFunc)("/v1/models")();
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "list_models_v1_models_get",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "GET",
+ path: path$,
+ headers: headers$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, components.ModelList$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=modelsList.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsList.js.map b/node_modules/@mistralai/mistralai/funcs/modelsList.js.map
new file mode 100644
index 0000000000..e9f69b0e9f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsList.js.map
@@ -0,0 +1 @@
+{"version":3,"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ralai/mistralai/funcs/modelsRetrieve.d.ts
new file mode 100644
index 0000000000..dd60f57098
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import * as errors from "../models/errors/index.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Retrieve Model
+ *
+ * @remarks
+ * Retrieve a model information.
+ */
+export declare function modelsRetrieve(client$: MistralCore, request: operations.RetrieveModelV1ModelsModelIdGetRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=modelsRetrieve.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.d.ts.map b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.d.ts.map
new file mode 100644
index 0000000000..9903252bc2
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsRetrieve.d.ts","sourceRoot":"","sources":["../src/funcs/modelsRetrieve.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,cAAc,CAClC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,sCAAsC,EAC1D,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,sEAAsE,EAC/E,MAAM,CAAC,mBAAmB,GAC1B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CA4FA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.js b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.js
new file mode 100644
index 0000000000..d5ed001f48
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.js
@@ -0,0 +1,102 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.modelsRetrieve = modelsRetrieve;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const errors = __importStar(require("../models/errors/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Retrieve Model
+ *
+ * @remarks
+ * Retrieve a model information.
+ */
+async function modelsRetrieve(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations.RetrieveModelV1ModelsModelIdGetRequest$outboundSchema.parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ model_id: (0, encodings_js_1.encodeSimple)("model_id", payload$.model_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/models/{model_id}")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "retrieve_model_v1_models__model_id__get",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "GET",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["422", "4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const responseFields$ = {
+ HttpMeta: { Response: response, Request: request$ },
+ };
+ const [result$] = await m$.match(m$.json(200, operations
+ .RetrieveModelV1ModelsModelIdGetResponseRetrieveModelV1ModelsModelIdGet$inboundSchema), m$.jsonErr(422, errors.HTTPValidationError$inboundSchema), m$.fail(["4XX", "5XX"]))(response, { extraFields: responseFields$ });
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=modelsRetrieve.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.js.map b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.js.map
new file mode 100644
index 0000000000..6ed55398dc
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsRetrieve.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsRetrieve.js","sourceRoot":"","sources":["../src/funcs/modelsRetrieve.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,wCA4GC;AArID,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAQ3C,kEAAoD;AAGpD,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,cAAc,CAClC,OAAoB,EACpB,OAA0D,EAC1D,OAAwB;IAcxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU,CAAC,qDAAqD,CAAC,KAAK,CACpE,MAAM,CACP,EACH,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,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ai/mistralai/funcs/modelsUnarchive.d.ts
new file mode 100644
index 0000000000..6980e0b31e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Unarchive Fine Tuned Model
+ *
+ * @remarks
+ * Un-archive a fine-tuned model.
+ */
+export declare function modelsUnarchive(client$: MistralCore, request: operations.JobsApiRoutesFineTuningUnarchiveFineTunedModelRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=modelsUnarchive.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.d.ts.map b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.d.ts.map
new file mode 100644
index 0000000000..dc62ca237d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsUnarchive.d.ts","sourceRoot":"","sources":["../src/funcs/modelsUnarchive.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAIzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,eAAe,CACnC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,qDAAqD,EACzE,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,mBAAmB,EAC5B,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAoFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.js b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.js
new file mode 100644
index 0000000000..dec1dfad53
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.js
@@ -0,0 +1,100 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.modelsUnarchive = modelsUnarchive;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Unarchive Fine Tuned Model
+ *
+ * @remarks
+ * Un-archive a fine-tuned model.
+ */
+async function modelsUnarchive(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations
+ .JobsApiRoutesFineTuningUnarchiveFineTunedModelRequest$outboundSchema
+ .parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = null;
+ const pathParams$ = {
+ model_id: (0, encodings_js_1.encodeSimple)("model_id", payload$.model_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/models/{model_id}/archive")(pathParams$);
+ const headers$ = new Headers({
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_unarchive_fine_tuned_model",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "DELETE",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.UnarchiveFTModelOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=modelsUnarchive.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.js.map b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.js.map
new file mode 100644
index 0000000000..e9e3ddf57f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUnarchive.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsUnarchive.js","sourceRoot":"","sources":["../src/funcs/modelsUnarchive.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA4BH,0CAmGC;AA5HD,sDAAoE;AACpE,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,eAAe,CACnC,OAAoB,EACpB,OAAyE,EACzE,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU;SACP,oEAAoE;SACpE,KAAK,CAAC,MAAM,CAAC,EAClB,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAI,CAAC;IAEnB,MAAM,WAAW,GAAG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AAM,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAE;QAC3C,OAAO;QACP,UAAU,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC;QAC1B,WAAW,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,OAAO;eACxB,OAAO,CAAC,QAAQ,CAAC,WAAW;QACjC,UAAU,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,iCAAiC,CAAC,EAC1D,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUpdate.d.ts b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.d.ts
new file mode 100644
index 0000000000..fa5d974db5
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.d.ts
@@ -0,0 +1,16 @@
+import { MistralCore } from "../core.js";
+import { RequestOptions } from "../lib/sdks.js";
+import * as components from "../models/components/index.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import * as operations from "../models/operations/index.js";
+import { Result } from "../types/fp.js";
+/**
+ * Update Fine Tuned Model
+ *
+ * @remarks
+ * Update a model name or description.
+ */
+export declare function modelsUpdate(client$: MistralCore, request: operations.JobsApiRoutesFineTuningUpdateFineTunedModelRequest, options?: RequestOptions): Promise>;
+//# sourceMappingURL=modelsUpdate.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUpdate.d.ts.map b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.d.ts.map
new file mode 100644
index 0000000000..45ade59e13
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsUpdate.d.ts","sourceRoot":"","sources":["../src/funcs/modelsUpdate.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAOzC,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAsB,YAAY,CAChC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,UAAU,CAAC,kDAAkD,EACtE,OAAO,CAAC,EAAE,cAAc,GACvB,OAAO,CACR,MAAM,CACJ,UAAU,CAAC,UAAU,EACnB,QAAQ,GACR,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAqFA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUpdate.js b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.js
new file mode 100644
index 0000000000..8af02cee55
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.js
@@ -0,0 +1,103 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.modelsUpdate = modelsUpdate;
+const encodings_js_1 = require("../lib/encodings.js");
+const m$ = __importStar(require("../lib/matchers.js"));
+const schemas$ = __importStar(require("../lib/schemas.js"));
+const security_js_1 = require("../lib/security.js");
+const url_js_1 = require("../lib/url.js");
+const components = __importStar(require("../models/components/index.js"));
+const operations = __importStar(require("../models/operations/index.js"));
+/**
+ * Update Fine Tuned Model
+ *
+ * @remarks
+ * Update a model name or description.
+ */
+async function modelsUpdate(client$, request, options) {
+ const input$ = request;
+ const parsed$ = schemas$.safeParse(input$, (value$) => operations
+ .JobsApiRoutesFineTuningUpdateFineTunedModelRequest$outboundSchema
+ .parse(value$), "Input validation failed");
+ if (!parsed$.ok) {
+ return parsed$;
+ }
+ const payload$ = parsed$.value;
+ const body$ = (0, encodings_js_1.encodeJSON)("body", payload$.UpdateFTModelIn, {
+ explode: true,
+ });
+ const pathParams$ = {
+ model_id: (0, encodings_js_1.encodeSimple)("model_id", payload$.model_id, {
+ explode: false,
+ charEncoding: "percent",
+ }),
+ };
+ const path$ = (0, url_js_1.pathToFunc)("/v1/fine_tuning/models/{model_id}")(pathParams$);
+ const headers$ = new Headers({
+ "Content-Type": "application/json",
+ Accept: "application/json",
+ });
+ const apiKey$ = await (0, security_js_1.extractSecurity)(client$.options$.apiKey);
+ const security$ = apiKey$ == null ? {} : { apiKey: apiKey$ };
+ const context = {
+ operationID: "jobs_api_routes_fine_tuning_update_fine_tuned_model",
+ oAuth2Scopes: [],
+ securitySource: client$.options$.apiKey,
+ };
+ const securitySettings$ = (0, security_js_1.resolveGlobalSecurity)(security$);
+ const requestRes = client$.createRequest$(context, {
+ security: securitySettings$,
+ method: "PATCH",
+ path: path$,
+ headers: headers$,
+ body: body$,
+ timeoutMs: (options === null || options === void 0 ? void 0 : options.timeoutMs) || client$.options$.timeoutMs || -1,
+ }, options);
+ if (!requestRes.ok) {
+ return requestRes;
+ }
+ const request$ = requestRes.value;
+ const doResult = await client$.do$(request$, {
+ context,
+ errorCodes: ["4XX", "5XX"],
+ retryConfig: (options === null || options === void 0 ? void 0 : options.retries)
+ || client$.options$.retryConfig,
+ retryCodes: (options === null || options === void 0 ? void 0 : options.retryCodes) || ["429", "500", "502", "503", "504"],
+ });
+ if (!doResult.ok) {
+ return doResult;
+ }
+ const response = doResult.value;
+ const [result$] = await m$.match(m$.json(200, components.FTModelOut$inboundSchema), m$.fail(["4XX", "5XX"]))(response);
+ if (!result$.ok) {
+ return result$;
+ }
+ return result$;
+}
+//# sourceMappingURL=modelsUpdate.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/funcs/modelsUpdate.js.map b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.js.map
new file mode 100644
index 0000000000..3315142ef0
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/funcs/modelsUpdate.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"modelsUpdate.js","sourceRoot":"","sources":["../src/funcs/modelsUpdate.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;AA+BH,oCAoGC;AAhID,sDAG6B;AAC7B,uDAAyC;AACzC,4DAA8C;AAE9C,oDAA4E;AAC5E,0CAA2C;AAC3C,0EAA4D;AAU5D,0EAA4D;AAG5D;;;;;GAKG;AACI,KAAK,UAAU,YAAY,CAChC,OAAoB,EACpB,OAAsE,EACtE,OAAwB;IAaxB,MAAM,MAAM,GAAG,OAAO,CAAC;IAEvB,MAAM,OAAO,GAAG,QAAQ,CAAC,SAAS,CAChC,MAAM,EACN,CAAC,MAAM,EAAE,EAAE,CACT,UAAU;SACP,iEAAiE;SACjE,KAAK,CAAC,MAAM,CAAC,EAClB,yBAAyB,CAC1B,CAAC;IACF,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IACD,MAAM,QAAQ,GAAG,OAAO,CAAC,KAAK,CAAC;IAC/B,MAAM,KAAK,GAAG,IAAA,yBAAW,EAAC,MAAM,EAAE,QAAQ,CAAC,eAAe,EAAE;QAC1D,OAAO,EAAE,IAAI;KACd,CAAC,CAAC;IAEH,MAAM,WAAW,GAAG;QAClB,QAAQ,EAAE,IAAA,2BAAa,EAAC,UAAU,EAAE,QAAQ,CAAC,QAAQ,EAAE;YACrD,OAAO,EAAE,KAAK;YACd,YAAY,EAAE,SAAS;SACxB,CAAC;KACH,CAAC;IAEF,MAAM,KAAK,GAAG,IAAA,mBAAU,EAAC,mCAAmC,CAAC,CAAC,WAAW,CAAC,C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C,WAAW;QACjC,UAAU,EAAE,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,UAAU,KAAI,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC;KACvE,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,QAAQ,CAAC;IAClB,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,EAAE,CAAC,KAAK,CAU9B,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,wBAAwB,CAAC,EACjD,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC,CACxB,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,OAAO,CAAC,EAAE,EAAE,CAAC;QAChB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,CAAC;AACjB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/custom_user_agent.d.ts b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.d.ts
new file mode 100644
index 0000000000..b2bce15d75
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.d.ts
@@ -0,0 +1,5 @@
+import { BeforeRequestContext, BeforeRequestHook, Awaitable } from "./types";
+export declare class CustomUserAgentHook implements BeforeRequestHook {
+ beforeRequest(_: BeforeRequestContext, request: Request): Awaitable;
+}
+//# sourceMappingURL=custom_user_agent.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/custom_user_agent.d.ts.map b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.d.ts.map
new file mode 100644
index 0000000000..da8909856e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"custom_user_agent.d.ts","sourceRoot":"","sources":["../src/hooks/custom_user_agent.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAE7E,qBAAa,mBAAoB,YAAW,iBAAiB;IAC3D,aAAa,CAAC,CAAC,EAAE,oBAAoB,EAAE,OAAO,EAAE,OAAO,GAAG,SAAS,CAAC,OAAO,CAAC;CAe7E"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/custom_user_agent.js b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.js
new file mode 100644
index 0000000000..e2ca0b5fb1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.js
@@ -0,0 +1,20 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.CustomUserAgentHook = void 0;
+const config_1 = require("../lib/config");
+class CustomUserAgentHook {
+ beforeRequest(_, request) {
+ const version = config_1.SDK_METADATA.sdkVersion;
+ const ua = `mistral-client-typescript/${version}`;
+ request.headers.set("user-agent", ua);
+ // In Chrome, the line above may silently fail. If the header was not set
+ // we fallback to setting an alternate header.
+ // Chromium bug: https://issues.chromium.org/issues/40450316
+ if (!request.headers.get("user-agent")) {
+ request.headers.set("x-mistral-user-agent", ua);
+ }
+ return request;
+ }
+}
+exports.CustomUserAgentHook = CustomUserAgentHook;
+//# sourceMappingURL=custom_user_agent.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/custom_user_agent.js.map b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.js.map
new file mode 100644
index 0000000000..9e36bdf304
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/custom_user_agent.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"custom_user_agent.js","sourceRoot":"","sources":["../src/hooks/custom_user_agent.ts"],"names":[],"mappings":";;;AAAA,0CAA6C;AAG7C,MAAa,mBAAmB;IAC9B,aAAa,CAAC,CAAuB,EAAE,OAAgB;QACrD,MAAM,OAAO,GAAG,qBAAY,CAAC,UAAU,CAAC;QACxC,MAAM,EAAE,GAAG,6BAA6B,OAAO,EAAE,CAAC;QAElD,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;QAEtC,yEAAyE;QACzE,8CAA8C;QAC9C,4DAA4D;QAC5D,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,YAAY,CAAC,EAAE,CAAC;YACvC,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,sBAAsB,EAAE,EAAE,CAAC,CAAC;QAClD,CAAC;QAED,OAAO,OAAO,CAAC;IACjB,CAAC;CACF;AAhBD,kDAgBC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/deprecation_warning.d.ts b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.d.ts
new file mode 100644
index 0000000000..89aa577b9c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.d.ts
@@ -0,0 +1,5 @@
+import { AfterSuccessContext, AfterSuccessHook, Awaitable } from './types';
+export declare class DeprecationWarningHook implements AfterSuccessHook {
+ afterSuccess(_: AfterSuccessContext, response: Response): Awaitable;
+}
+//# sourceMappingURL=deprecation_warning.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/deprecation_warning.d.ts.map b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.d.ts.map
new file mode 100644
index 0000000000..9a3fc87ede
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"deprecation_warning.d.ts","sourceRoot":"","sources":["../src/hooks/deprecation_warning.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAK3E,qBAAa,sBAAuB,YAAW,gBAAgB;IAC3D,YAAY,CAAC,CAAC,EAAE,mBAAmB,EAAE,QAAQ,EAAE,QAAQ,GAAG,SAAS,CAAC,QAAQ,CAAC;CAYhF"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/deprecation_warning.js b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.js
new file mode 100644
index 0000000000..4ca3e50365
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.js
@@ -0,0 +1,17 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.DeprecationWarningHook = void 0;
+const HEADER_MODEL_DEPRECATION_TIMESTAMP = "x-model-deprecation-timestamp";
+class DeprecationWarningHook {
+ afterSuccess(_, response) {
+ if (response.headers.has(HEADER_MODEL_DEPRECATION_TIMESTAMP)) {
+ response.clone().json().then((body) => {
+ const model = body.model;
+ console.warn(`WARNING: The model ${model} is deprecated and will be removed on ${response.headers.get(HEADER_MODEL_DEPRECATION_TIMESTAMP)}. Please refer to https://docs.mistral.ai/getting-started/models/#api-versioning for more information.`);
+ });
+ }
+ return response;
+ }
+}
+exports.DeprecationWarningHook = DeprecationWarningHook;
+//# sourceMappingURL=deprecation_warning.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/deprecation_warning.js.map b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.js.map
new file mode 100644
index 0000000000..6ef9b81784
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/deprecation_warning.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"deprecation_warning.js","sourceRoot":"","sources":["../src/hooks/deprecation_warning.ts"],"names":[],"mappings":";;;AAGA,MAAM,kCAAkC,GAAG,+BAA+B,CAAC;AAE3E,MAAa,sBAAsB;IAC/B,YAAY,CAAC,CAAsB,EAAE,QAAkB;QACnD,IAAI,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,EAAE,CAAC;YAC3D,QAAQ,CAAC,KAAK,EAAE,CAAC,IAAI,EAAE,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE;gBAClC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;gBACzB,OAAO,CAAC,IAAI,CACR,sBAAsB,KAAK,yCAAyC,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,wGAAwG,CACvO,CAAC;YACN,CAAC,CAAC,CAAC;QAEP,CAAC;QACD,OAAO,QAAQ,CAAC;IACpB,CAAC;CACJ;AAbD,wDAaC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/hooks.d.ts b/node_modules/@mistralai/mistralai/hooks/hooks.d.ts
new file mode 100644
index 0000000000..90516bace0
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/hooks.d.ts
@@ -0,0 +1,24 @@
+import { RequestInput } from "../lib/http.js";
+import { AfterErrorContext, AfterErrorHook, AfterSuccessContext, AfterSuccessHook, BeforeCreateRequestContext, BeforeCreateRequestHook, BeforeRequestContext, BeforeRequestHook, Hooks, SDKInitHook, SDKInitOptions } from "./types.js";
+export declare class SDKHooks implements Hooks {
+ sdkInitHooks: SDKInitHook[];
+ beforeCreateRequestHooks: BeforeCreateRequestHook[];
+ beforeRequestHooks: BeforeRequestHook[];
+ afterSuccessHooks: AfterSuccessHook[];
+ afterErrorHooks: AfterErrorHook[];
+ constructor();
+ registerSDKInitHook(hook: SDKInitHook): void;
+ registerBeforeCreateRequestHook(hook: BeforeCreateRequestHook): void;
+ registerBeforeRequestHook(hook: BeforeRequestHook): void;
+ registerAfterSuccessHook(hook: AfterSuccessHook): void;
+ registerAfterErrorHook(hook: AfterErrorHook): void;
+ sdkInit(opts: SDKInitOptions): SDKInitOptions;
+ beforeCreateRequest(hookCtx: BeforeCreateRequestContext, input: RequestInput): RequestInput;
+ beforeRequest(hookCtx: BeforeRequestContext, request: Request): Promise;
+ afterSuccess(hookCtx: AfterSuccessContext, response: Response): Promise;
+ afterError(hookCtx: AfterErrorContext, response: Response | null, error: unknown): Promise<{
+ response: Response | null;
+ error: unknown;
+ }>;
+}
+//# sourceMappingURL=hooks.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/hooks.d.ts.map b/node_modules/@mistralai/mistralai/hooks/hooks.d.ts.map
new file mode 100644
index 0000000000..ec542388ca
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/hooks.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../src/hooks/hooks.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EACL,iBAAiB,EACjB,cAAc,EACd,mBAAmB,EACnB,gBAAgB,EAChB,0BAA0B,EAC1B,uBAAuB,EACvB,oBAAoB,EACpB,iBAAiB,EACjB,KAAK,EACL,WAAW,EACX,cAAc,EACf,MAAM,YAAY,CAAC;AAIpB,qBAAa,QAAS,YAAW,KAAK;IACpC,YAAY,EAAE,WAAW,EAAE,CAAM;IACjC,wBAAwB,EAAE,uBAAuB,EAAE,CAAM;IACzD,kBAAkB,EAAE,iBAAiB,EAAE,CAAM;IAC7C,iBAAiB,EAAE,gBAAgB,EAAE,CAAM;IAC3C,eAAe,EAAE,cAAc,EAAE,CAAM;;IAMvC,mBAAmB,CAAC,IAAI,EAAE,WAAW;IAIrC,+BAA+B,CAAC,IAAI,EAAE,uBAAuB;IAI7D,yBAAyB,CAAC,IAAI,EAAE,iBAAiB;IAIjD,wBAAwB,CAAC,IAAI,EAAE,gBAAgB;IAI/C,sBAAsB,CAAC,IAAI,EAAE,cAAc;IAI3C,OAAO,CAAC,IAAI,EAAE,cAAc,GAAG,cAAc;IAI7C,mBAAmB,CACjB,OAAO,EAAE,0BAA0B,EACnC,KAAK,EAAE,YAAY,GAClB,YAAY;IAUT,aAAa,CACjB,OAAO,EAAE,oBAAoB,EAC7B,OAAO,EAAE,OAAO,GACf,OAAO,CAAC,OAAO,CAAC;IAUb,YAAY,CAChB,OAAO,EAAE,mBAAmB,EAC5B,QAAQ,EAAE,QAAQ,GACjB,OAAO,CAAC,QAAQ,CAAC;IAUd,UAAU,CACd,OAAO,EAAE,iBAAiB,EAC1B,QAAQ,EAAE,QAAQ,GAAG,IAAI,EACzB,KAAK,EAAE,OAAO,GACb,OAAO,CAAC;QAAE,QAAQ,EAAE,QAAQ,GAAG,IAAI,CAAC;QAAC,KAAK,EAAE,OAAO,CAAA;KAAE,CAAC;CAY1D"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/hooks.js b/node_modules/@mistralai/mistralai/hooks/hooks.js
new file mode 100644
index 0000000000..e47cf193f3
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/hooks.js
@@ -0,0 +1,68 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.SDKHooks = void 0;
+const registration_js_1 = require("./registration.js");
+class SDKHooks {
+ constructor() {
+ this.sdkInitHooks = [];
+ this.beforeCreateRequestHooks = [];
+ this.beforeRequestHooks = [];
+ this.afterSuccessHooks = [];
+ this.afterErrorHooks = [];
+ (0, registration_js_1.initHooks)(this);
+ }
+ registerSDKInitHook(hook) {
+ this.sdkInitHooks.push(hook);
+ }
+ registerBeforeCreateRequestHook(hook) {
+ this.beforeCreateRequestHooks.push(hook);
+ }
+ registerBeforeRequestHook(hook) {
+ this.beforeRequestHooks.push(hook);
+ }
+ registerAfterSuccessHook(hook) {
+ this.afterSuccessHooks.push(hook);
+ }
+ registerAfterErrorHook(hook) {
+ this.afterErrorHooks.push(hook);
+ }
+ sdkInit(opts) {
+ return this.sdkInitHooks.reduce((opts, hook) => hook.sdkInit(opts), opts);
+ }
+ beforeCreateRequest(hookCtx, input) {
+ let inp = input;
+ for (const hook of this.beforeCreateRequestHooks) {
+ inp = hook.beforeCreateRequest(hookCtx, inp);
+ }
+ return inp;
+ }
+ async beforeRequest(hookCtx, request) {
+ let req = request;
+ for (const hook of this.beforeRequestHooks) {
+ req = await hook.beforeRequest(hookCtx, req);
+ }
+ return req;
+ }
+ async afterSuccess(hookCtx, response) {
+ let res = response;
+ for (const hook of this.afterSuccessHooks) {
+ res = await hook.afterSuccess(hookCtx, res);
+ }
+ return res;
+ }
+ async afterError(hookCtx, response, error) {
+ let res = response;
+ let err = error;
+ for (const hook of this.afterErrorHooks) {
+ const result = await hook.afterError(hookCtx, res, err);
+ res = result.response;
+ err = result.error;
+ }
+ return { response: res, error: err };
+ }
+}
+exports.SDKHooks = SDKHooks;
+//# sourceMappingURL=hooks.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/hooks.js.map b/node_modules/@mistralai/mistralai/hooks/hooks.js.map
new file mode 100644
index 0000000000..cef58ca31b
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/hooks.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"hooks.js","sourceRoot":"","sources":["../src/hooks/hooks.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAiBH,uDAA8C;AAE9C,MAAa,QAAQ;IAOnB;QANA,iBAAY,GAAkB,EAAE,CAAC;QACjC,6BAAwB,GAA8B,EAAE,CAAC;QACzD,uBAAkB,GAAwB,EAAE,CAAC;QAC7C,sBAAiB,GAAuB,EAAE,CAAC;QAC3C,oBAAe,GAAqB,EAAE,CAAC;QAGrC,IAAA,2BAAS,EAAC,IAAI,CAAC,CAAC;IAClB,CAAC;IAED,mBAAmB,CAAC,IAAiB;QACnC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC/B,CAAC;IAED,+BAA+B,CAAC,IAA6B;QAC3D,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC3C,CAAC;IAED,yBAAyB,CAAC,IAAuB;QAC/C,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACrC,CAAC;IAED,wBAAwB,CAAC,I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yB,EACzB,KAAc;QAEd,IAAI,GAAG,GAAG,QAAQ,CAAC;QACnB,IAAI,GAAG,GAAG,KAAK,CAAC;QAEhB,KAAK,MAAM,IAAI,IAAI,IAAI,CAAC,eAAe,EAAE,CAAC;YACxC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC;YACxD,GAAG,GAAG,MAAM,CAAC,QAAQ,CAAC;YACtB,GAAG,GAAG,MAAM,CAAC,KAAK,CAAC;QACrB,CAAC;QAED,OAAO,EAAE,QAAQ,EAAE,GAAG,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC;IACvC,CAAC;CACF;AA1FD,4BA0FC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/index.d.ts b/node_modules/@mistralai/mistralai/hooks/index.d.ts
new file mode 100644
index 0000000000..c609283271
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/index.d.ts
@@ -0,0 +1,3 @@
+export * from "./hooks.js";
+export * from "./types.js";
+//# sourceMappingURL=index.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/index.d.ts.map b/node_modules/@mistralai/mistralai/hooks/index.d.ts.map
new file mode 100644
index 0000000000..22d6d356f4
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/index.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/hooks/index.ts"],"names":[],"mappings":"AAIA,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/index.js b/node_modules/@mistralai/mistralai/hooks/index.js
new file mode 100644
index 0000000000..90d8b01adb
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/index.js
@@ -0,0 +1,22 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __exportStar = (this && this.__exportStar) || function(m, exports) {
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+__exportStar(require("./hooks.js"), exports);
+__exportStar(require("./types.js"), exports);
+//# sourceMappingURL=index.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/index.js.map b/node_modules/@mistralai/mistralai/hooks/index.js.map
new file mode 100644
index 0000000000..683ec3fd78
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/index.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/hooks/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;AAEH,6CAA2B;AAC3B,6CAA2B"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/registration.d.ts b/node_modules/@mistralai/mistralai/hooks/registration.d.ts
new file mode 100644
index 0000000000..cfb4c064b6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/registration.d.ts
@@ -0,0 +1,3 @@
+import { Hooks } from "./types";
+export declare function initHooks(hooks: Hooks): void;
+//# sourceMappingURL=registration.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/registration.d.ts.map b/node_modules/@mistralai/mistralai/hooks/registration.d.ts.map
new file mode 100644
index 0000000000..d9cd522753
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/registration.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"registration.d.ts","sourceRoot":"","sources":["../src/hooks/registration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAWhC,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,QAUrC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/registration.js b/node_modules/@mistralai/mistralai/hooks/registration.js
new file mode 100644
index 0000000000..1af003e210
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/registration.js
@@ -0,0 +1,20 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.initHooks = initHooks;
+const custom_user_agent_1 = require("./custom_user_agent");
+const deprecation_warning_1 = require("./deprecation_warning");
+/*
+ * This file is only ever generated once on the first generation and then is free to be modified.
+ * Any hooks you wish to add should be registered in the initHooks function. Feel free to define them
+ * in this file or in separate files in the hooks folder.
+ */
+function initHooks(hooks) {
+ // Add hooks by calling hooks.register{ClientInit/BeforeCreateRequest/BeforeRequest/AfterSuccess/AfterError}Hook
+ // with an instance of a hook that implements that specific Hook interface
+ // Hooks are registered per SDK instance, and are valid for the lifetime of the SDK instance
+ const customUserAgentHook = new custom_user_agent_1.CustomUserAgentHook();
+ hooks.registerBeforeRequestHook(customUserAgentHook);
+ const deprecationWarningHook = new deprecation_warning_1.DeprecationWarningHook();
+ hooks.registerAfterSuccessHook(deprecationWarningHook);
+}
+//# sourceMappingURL=registration.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/registration.js.map b/node_modules/@mistralai/mistralai/hooks/registration.js.map
new file mode 100644
index 0000000000..c6afad254a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/registration.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"registration.js","sourceRoot":"","sources":["../src/hooks/registration.ts"],"names":[],"mappings":";;AAWA,8BAUC;AApBD,2DAA0D;AAC1D,+DAA+D;AAE/D;;;;GAIG;AAGH,SAAgB,SAAS,CAAC,KAAY;IAClC,gHAAgH;IAChH,0EAA0E;IAC1E,4FAA4F;IAC5F,MAAM,mBAAmB,GAAG,IAAI,uCAAmB,EAAE,CAAC;IACtD,KAAK,CAAC,yBAAyB,CAAC,mBAAmB,CAAC,CAAA;IAEpD,MAAM,sBAAsB,GAAG,IAAI,4CAAsB,EAAE,CAAC;IAC5D,KAAK,CAAC,wBAAwB,CAAC,sBAAsB,CAAC,CAAA;AAE1D,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/types.d.ts b/node_modules/@mistralai/mistralai/hooks/types.d.ts
new file mode 100644
index 0000000000..9389bd2419
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/types.d.ts
@@ -0,0 +1,72 @@
+import { HTTPClient, RequestInput } from "../lib/http.js";
+export type HookContext = {
+ operationID: string;
+ oAuth2Scopes?: string[];
+ securitySource?: any | (() => Promise);
+};
+export type Awaitable = T | Promise;
+export type SDKInitOptions = {
+ baseURL: URL | null;
+ client: HTTPClient;
+};
+export type BeforeCreateRequestContext = HookContext & {};
+export type BeforeRequestContext = HookContext & {};
+export type AfterSuccessContext = HookContext & {};
+export type AfterErrorContext = HookContext & {};
+/**
+ * SDKInitHook is called when the SDK is initializing. The
+ * hook can return a new baseURL and HTTP client to be used by the SDK.
+ */
+export interface SDKInitHook {
+ sdkInit: (opts: SDKInitOptions) => SDKInitOptions;
+}
+export interface BeforeCreateRequestHook {
+ /**
+ * A hook that is called before the SDK creates a `Request` object. The hook
+ * can modify how a request is constructed since certain modifications, like
+ * changing the request URL, cannot be done on a request object directly.
+ */
+ beforeCreateRequest: (hookCtx: BeforeCreateRequestContext, input: RequestInput) => RequestInput;
+}
+export interface BeforeRequestHook {
+ /**
+ * A hook that is called before the SDK sends a request. The hook can
+ * introduce instrumentation code such as logging, tracing and metrics or
+ * replace the request before it is sent or throw an error to stop the
+ * request from being sent.
+ */
+ beforeRequest: (hookCtx: BeforeRequestContext, request: Request) => Awaitable;
+}
+export interface AfterSuccessHook {
+ /**
+ * A hook that is called after the SDK receives a response. The hook can
+ * introduce instrumentation code such as logging, tracing and metrics or
+ * modify the response before it is handled or throw an error to stop the
+ * response from being handled.
+ */
+ afterSuccess: (hookCtx: AfterSuccessContext, response: Response) => Awaitable;
+}
+export interface AfterErrorHook {
+ /**
+ * A hook that is called after the SDK encounters an error, or a
+ * non-successful response. The hook can introduce instrumentation code such
+ * as logging, tracing and metrics or modify the response or error values.
+ */
+ afterError: (hookCtx: AfterErrorContext, response: Response | null, error: unknown) => Awaitable<{
+ response: Response | null;
+ error: unknown;
+ }>;
+}
+export interface Hooks {
+ /** Registers a hook to be used by the SDK for initialization event. */
+ registerSDKInitHook(hook: SDKInitHook): void;
+ /** Registers a hook to be used by the SDK for to modify `Request` construction. */
+ registerBeforeCreateRequestHook(hook: BeforeCreateRequestHook): void;
+ /** Registers a hook to be used by the SDK for the before request event. */
+ registerBeforeRequestHook(hook: BeforeRequestHook): void;
+ /** Registers a hook to be used by the SDK for the after success event. */
+ registerAfterSuccessHook(hook: AfterSuccessHook): void;
+ /** Registers a hook to be used by the SDK for the after error event. */
+ registerAfterErrorHook(hook: AfterErrorHook): void;
+}
+//# sourceMappingURL=types.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/types.d.ts.map b/node_modules/@mistralai/mistralai/hooks/types.d.ts.map
new file mode 100644
index 0000000000..218d77855a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/types.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/hooks/types.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE1D,MAAM,MAAM,WAAW,GAAG;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,GAAG,GAAG,CAAC,MAAM,OAAO,CAAC,GAAG,CAAC,CAAC,C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KAChB,CAAC,CAAC;CACJ;AAED,MAAM,WAAW,KAAK;IACpB,uEAAuE;IACvE,mBAAmB,CAAC,IAAI,EAAE,WAAW,GAAG,IAAI,CAAC;IAC7C,mFAAmF;IACnF,+BAA+B,CAAC,IAAI,EAAE,uBAAuB,GAAG,IAAI,CAAC;IACrE,2EAA2E;IAC3E,yBAAyB,CAAC,IAAI,EAAE,iBAAiB,GAAG,IAAI,CAAC;IACzD,0EAA0E;IAC1E,wBAAwB,CAAC,IAAI,EAAE,gBAAgB,GAAG,IAAI,CAAC;IACvD,wEAAwE;IACxE,sBAAsB,CAAC,IAAI,EAAE,cAAc,GAAG,IAAI,CAAC;CACpD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/types.js b/node_modules/@mistralai/mistralai/hooks/types.js
new file mode 100644
index 0000000000..5b19986536
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/types.js
@@ -0,0 +1,6 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+//# sourceMappingURL=types.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/hooks/types.js.map b/node_modules/@mistralai/mistralai/hooks/types.js.map
new file mode 100644
index 0000000000..fb4554f71e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/hooks/types.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/hooks/types.ts"],"names":[],"mappings":";AAAA;;GAEG"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/index.d.ts b/node_modules/@mistralai/mistralai/index.d.ts
new file mode 100644
index 0000000000..eed360610a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/index.d.ts
@@ -0,0 +1,4 @@
+export * from "./lib/config.js";
+export * as files from "./lib/files.js";
+export * from "./sdk/sdk.js";
+//# sourceMappingURL=index.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/index.d.ts.map b/node_modules/@mistralai/mistralai/index.d.ts.map
new file mode 100644
index 0000000000..e329d842af
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/index.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"AAIA,cAAc,iBAAiB,CAAC;AAChC,OAAO,KAAK,KAAK,MAAM,gBAAgB,CAAC;AACxC,cAAc,cAAc,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/index.js b/node_modules/@mistralai/mistralai/index.js
new file mode 100644
index 0000000000..17b02fb537
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/index.js
@@ -0,0 +1,36 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __exportStar = (this && this.__exportStar) || function(m, exports) {
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
+};
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.files = void 0;
+__exportStar(require("./lib/config.js"), exports);
+exports.files = __importStar(require("./lib/files.js"));
+__exportStar(require("./sdk/sdk.js"), exports);
+//# sourceMappingURL=index.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/index.js.map b/node_modules/@mistralai/mistralai/index.js.map
new file mode 100644
index 0000000000..31d09b7434
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/index.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.js","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,kDAAgC;AAChC,wDAAwC;AACxC,+CAA6B"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/base64.d.ts b/node_modules/@mistralai/mistralai/lib/base64.d.ts
new file mode 100644
index 0000000000..0fe2fa3dd0
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/base64.d.ts
@@ -0,0 +1,10 @@
+import * as z from "zod";
+export declare function bytesToBase64(u8arr: Uint8Array): string;
+export declare function bytesFromBase64(encoded: string): Uint8Array;
+export declare function stringToBytes(str: string): Uint8Array;
+export declare function stringFromBytes(u8arr: Uint8Array): string;
+export declare function stringToBase64(str: string): string;
+export declare function stringFromBase64(b64str: string): string;
+export declare const zodOutbound: z.ZodUnion<[z.ZodType, z.ZodEffects]>;
+export declare const zodInbound: z.ZodUnion<[z.ZodType, z.ZodEffects]>;
+//# sourceMappingURL=base64.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/base64.d.ts.map b/node_modules/@mistralai/mistralai/lib/base64.d.ts.map
new file mode 100644
index 0000000000..ba3029254d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/base64.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"base64.d.ts","sourceRoot":"","sources":["../src/lib/base64.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,wBAAgB,aAAa,CAAC,KAAK,EAAE,UAAU,GAAG,MAAM,CAEvD;AAED,wBAAgB,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,UAAU,CAE3D;AAED,wBAAgB,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAErD;AAED,wBAAgB,eAAe,CAAC,KAAK,EAAE,UAAU,GAAG,MAAM,CAEzD;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAElD;AAED,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAEvD;AAED,eAAO,MAAM,WAAW,8GAEkB,CAAC;AAE3C,eAAO,MAAM,UAAU,8GAEqB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/base64.js b/node_modules/@mistralai/mistralai/lib/base64.js
new file mode 100644
index 0000000000..0186193f5e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/base64.js
@@ -0,0 +1,61 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.zodInbound = exports.zodOutbound = void 0;
+exports.bytesToBase64 = bytesToBase64;
+exports.bytesFromBase64 = bytesFromBase64;
+exports.stringToBytes = stringToBytes;
+exports.stringFromBytes = stringFromBytes;
+exports.stringToBase64 = stringToBase64;
+exports.stringFromBase64 = stringFromBase64;
+const z = __importStar(require("zod"));
+function bytesToBase64(u8arr) {
+ return btoa(String.fromCodePoint(...u8arr));
+}
+function bytesFromBase64(encoded) {
+ return Uint8Array.from(atob(encoded), (c) => c.charCodeAt(0));
+}
+function stringToBytes(str) {
+ return new TextEncoder().encode(str);
+}
+function stringFromBytes(u8arr) {
+ return new TextDecoder().decode(u8arr);
+}
+function stringToBase64(str) {
+ return bytesToBase64(stringToBytes(str));
+}
+function stringFromBase64(b64str) {
+ return stringFromBytes(bytesFromBase64(b64str));
+}
+exports.zodOutbound = z
+ .instanceof(Uint8Array)
+ .or(z.string().transform(stringToBytes));
+exports.zodInbound = z
+ .instanceof(Uint8Array)
+ .or(z.string().transform(bytesFromBase64));
+//# sourceMappingURL=base64.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/base64.js.map b/node_modules/@mistralai/mistralai/lib/base64.js.map
new file mode 100644
index 0000000000..7936a8ea9e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/base64.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"base64.js","sourceRoot":"","sources":["../src/lib/base64.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAIH,sCAEC;AAED,0CAEC;AAED,sCAEC;AAED,0CAEC;AAED,wCAEC;AAED,4CAEC;AAxBD,uCAAyB;AAEzB,SAAgB,aAAa,CAAC,KAAiB;IAC7C,OAAO,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC,GAAG,KAAK,CAAC,CAAC,CAAC;AAC9C,CAAC;AAED,SAAgB,eAAe,CAAC,OAAe;IAC7C,OAAO,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC;AAChE,CAAC;AAED,SAAgB,aAAa,CAAC,GAAW;IACvC,OAAO,IAAI,WAAW,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;AACvC,CAAC;AAED,SAAgB,eAAe,CAAC,KAAiB;IAC/C,OAAO,IAAI,WAAW,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;AACzC,CAAC;AAED,SAAgB,cAAc,CAAC,GAAW;IACxC,OAAO,aAAa,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC;AAC3C,CAAC;AAED,SAAgB,gBAAgB,CAAC,MAAc;IAC7C,OAAO,eAAe,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC;AAClD,CAAC;AAEY,QAAA,WAAW,GAAG,CAAC;KACzB,UAAU,CAAC,UAAU,CAAC;KACtB,EAAE,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC;AAE9B,QAAA,UAAU,GAAG,CAAC;KACxB,UAAU,CAAC,UAAU,CAAC;KACtB,EAAE,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,eAAe,CAAC,CAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/config.d.ts b/node_modules/@mistralai/mistralai/lib/config.d.ts
new file mode 100644
index 0000000000..c001a14b54
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/config.d.ts
@@ -0,0 +1,40 @@
+import { HTTPClient } from "./http.js";
+import { Logger } from "./logger.js";
+import { RetryConfig } from "./retries.js";
+/**
+ * Production server
+ */
+export declare const ServerProd = "prod";
+/**
+ * Contains the list of servers available to the SDK
+ */
+export declare const ServerList: {
+ readonly prod: "https://api.mistral.ai";
+};
+export type SDKOptions = {
+ apiKey?: string | (() => Promise);
+ httpClient?: HTTPClient;
+ /**
+ * Allows overriding the default server used by the SDK
+ */
+ server?: keyof typeof ServerList;
+ /**
+ * Allows overriding the default server URL used by the SDK
+ */
+ serverURL?: string;
+ /**
+ * Allows overriding the default retry config used by the SDK
+ */
+ retryConfig?: RetryConfig;
+ timeoutMs?: number;
+ debugLogger?: Logger;
+};
+export declare function serverURLFromOptions(options: SDKOptions): URL | null;
+export declare const SDK_METADATA: {
+ readonly language: "typescript";
+ readonly openapiDocVersion: "0.0.2";
+ readonly sdkVersion: "1.1.0";
+ readonly genVersion: "2.420.2";
+ readonly userAgent: "speakeasy-sdk/typescript 1.1.0 2.420.2 0.0.2 @mistralai/mistralai";
+};
+//# sourceMappingURL=config.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/config.d.ts.map b/node_modules/@mistralai/mistralai/lib/config.d.ts.map
new file mode 100644
index 0000000000..bc4a3c12fd
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/config.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/lib/config.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAG3C;;GAEG;AACH,eAAO,MAAM,UAAU,SAAS,CAAC;AACjC;;GAEG;AACH,eAAO,MAAM,UAAU;;CAEb,CAAC;AAEX,MAAM,MAAM,UAAU,GAAG;IACvB,MAAM,CAAC,EAAE,MAAM,GAAG,CAAC,MAAM,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC;IAE1C,UAAU,CAAC,EAAE,UAAU,CAAC;IACxB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,OAAO,UAAU,CAAC;IACjC;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,UAAU,GAAG,GAAG,GAAG,IAAI,CAYpE;AAED,eAAO,MAAM,YAAY;;;;;;CAOf,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/config.js b/node_modules/@mistralai/mistralai/lib/config.js
new file mode 100644
index 0000000000..8764785120
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/config.js
@@ -0,0 +1,37 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.SDK_METADATA = exports.ServerList = exports.ServerProd = void 0;
+exports.serverURLFromOptions = serverURLFromOptions;
+const url_js_1 = require("./url.js");
+/**
+ * Production server
+ */
+exports.ServerProd = "prod";
+/**
+ * Contains the list of servers available to the SDK
+ */
+exports.ServerList = {
+ [exports.ServerProd]: "https://api.mistral.ai",
+};
+function serverURLFromOptions(options) {
+ var _a;
+ let serverURL = options.serverURL;
+ const params = {};
+ if (!serverURL) {
+ const server = (_a = options.server) !== null && _a !== void 0 ? _a : exports.ServerProd;
+ serverURL = exports.ServerList[server] || "";
+ }
+ const u = (0, url_js_1.pathToFunc)(serverURL)(params);
+ return new URL(u);
+}
+exports.SDK_METADATA = {
+ language: "typescript",
+ openapiDocVersion: "0.0.2",
+ sdkVersion: "1.1.0",
+ genVersion: "2.420.2",
+ userAgent: "speakeasy-sdk/typescript 1.1.0 2.420.2 0.0.2 @mistralai/mistralai",
+};
+//# sourceMappingURL=config.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/config.js.map b/node_modules/@mistralai/mistralai/lib/config.js.map
new file mode 100644
index 0000000000..9461782434
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/config.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/lib/config.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAsCH,oDAYC;AA7CD,qCAA8C;AAE9C;;GAEG;AACU,QAAA,UAAU,GAAG,MAAM,CAAC;AACjC;;GAEG;AACU,QAAA,UAAU,GAAG;IACxB,CAAC,kBAAU,CAAC,EAAE,wBAAwB;CAC9B,CAAC;AAsBX,SAAgB,oBAAoB,CAAC,OAAmB;;IACtD,IAAI,SAAS,GAAG,OAAO,CAAC,SAAS,CAAC;IAElC,MAAM,MAAM,GAAW,EAAE,CAAC;IAE1B,IAAI,CAAC,SAAS,EAAE,CAAC;QACf,MAAM,MAAM,GAAG,MAAA,OAAO,CAAC,MAAM,mCAAI,kBAAU,CAAC;QAC5C,SAAS,GAAG,kBAAU,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;IACvC,CAAC;IAED,MAAM,CAAC,GAAG,IAAA,mBAAU,EAAC,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC;IACxC,OAAO,IAAI,GAAG,CAAC,CAAC,CAAC,CAAC;AACpB,CAAC;AAEY,QAAA,YAAY,GAAG;IAC1B,QAAQ,EAAE,YAAY;IACtB,iBAAiB,EAAE,OAAO;IAC1B,UAAU,EAAE,OAAO;IACnB,UAAU,EAAE,SAAS;IACrB,SAAS,EACP,mEAAmE;CAC7D,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/dlv.d.ts b/node_modules/@mistralai/mistralai/lib/dlv.d.ts
new file mode 100644
index 0000000000..a3239e1e77
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/dlv.d.ts
@@ -0,0 +1,14 @@
+/**
+ * @param obj The object to walk
+ * @param key The key path to walk the object with
+ * @param def A default value to return if the result is undefined
+ *
+ * @example
+ * dlv(obj, "a.b.c.d")
+ * @example
+ * dlv(object, ["a", "b", "c", "d"])
+ * @example
+ * dlv(object, "foo.bar.baz", "Hello, default value!")
+ */
+export declare function dlv(obj: any, key: string | string[], def?: T, p?: number, undef?: never): T | undefined;
+//# sourceMappingURL=dlv.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/dlv.d.ts.map b/node_modules/@mistralai/mistralai/lib/dlv.d.ts.map
new file mode 100644
index 0000000000..8a68c069be
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/dlv.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"dlv.d.ts","sourceRoot":"","sources":["../src/lib/dlv.ts"],"names":[],"mappings":"AA2BA;;;;;;;;;;;GAWG;AACH,wBAAgB,GAAG,CAAC,CAAC,GAAG,GAAG,EACzB,GAAG,EAAE,GAAG,EACR,GAAG,EAAE,MAAM,GAAG,MAAM,EAAE,EACtB,GAAG,CAAC,EAAE,CAAC,EACP,CAAC,CAAC,EAAE,MAAM,EACV,KAAK,CAAC,EAAE,KAAK,GACZ,CAAC,GAAG,SAAS,CAOf"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/dlv.js b/node_modules/@mistralai/mistralai/lib/dlv.js
new file mode 100644
index 0000000000..ac2161ea50
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/dlv.js
@@ -0,0 +1,49 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.dlv = dlv;
+/*
+MIT License
+
+Copyright (c) 2024 Jason Miller (http://jasonformat.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
+/**
+ * @param obj The object to walk
+ * @param key The key path to walk the object with
+ * @param def A default value to return if the result is undefined
+ *
+ * @example
+ * dlv(obj, "a.b.c.d")
+ * @example
+ * dlv(object, ["a", "b", "c", "d"])
+ * @example
+ * dlv(object, "foo.bar.baz", "Hello, default value!")
+ */
+function dlv(obj, key, def, p, undef) {
+ key = Array.isArray(key) ? key : key.split(".");
+ for (p = 0; p < key.length; p++) {
+ const k = key[p];
+ obj = k != null && obj ? obj[k] : undef;
+ }
+ return obj === undef ? def : obj;
+}
+//# sourceMappingURL=dlv.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/dlv.js.map b/node_modules/@mistralai/mistralai/lib/dlv.js.map
new file mode 100644
index 0000000000..7973403d57
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/dlv.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"dlv.js","sourceRoot":"","sources":["../src/lib/dlv.ts"],"names":[],"mappings":";AAAA;;GAEG;;AAqCH,kBAaC;AAhDD;;;;;;;;;;;;;;;;;;;;;EAqBE;AAEF;;;;;;;;;;;GAWG;AACH,SAAgB,GAAG,CACjB,GAAQ,EACR,GAAsB,EACtB,GAAO,EACP,CAAU,EACV,KAAa;IAEb,GAAG,GAAG,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAChD,KAAK,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QAChC,MAAM,CAAC,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC;QACjB,GAAG,GAAG,CAAC,IAAI,IAAI,IAAI,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;IAC1C,CAAC;IACD,OAAO,GAAG,KAAK,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC;AACnC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/encodings.d.ts b/node_modules/@mistralai/mistralai/lib/encodings.d.ts
new file mode 100644
index 0000000000..ef192683ad
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/encodings.d.ts
@@ -0,0 +1,51 @@
+export declare class EncodingError extends Error {
+ constructor(message: string);
+}
+export declare function encodeMatrix(key: string, value: unknown, options?: {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+}): string;
+export declare function encodeLabel(key: string, value: unknown, options?: {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+}): string;
+type FormEncoder = (key: string, value: unknown, options?: {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+}) => string;
+export declare const encodeForm: FormEncoder;
+export declare const encodeSpaceDelimited: FormEncoder;
+export declare const encodePipeDelimited: FormEncoder;
+export declare function encodeBodyForm(key: string, value: unknown, options?: {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+}): string;
+export declare function encodeDeepObject(key: string, value: unknown, options?: {
+ charEncoding?: "percent" | "none";
+}): string;
+export declare function encodeDeepObjectObject(key: string, value: unknown, options?: {
+ charEncoding?: "percent" | "none";
+}): string;
+export declare function encodeJSON(key: string, value: unknown, options?: {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+}): string;
+export declare const encodeSimple: (key: string, value: unknown, options?: {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+}) => string;
+export declare function queryJoin(...args: string[]): string;
+type QueryEncoderOptions = {
+ explode?: boolean;
+ charEncoding?: "percent" | "none";
+};
+type QueryEncoder = (key: string, value: unknown, options?: QueryEncoderOptions) => string;
+type BulkQueryEncoder = (values: Record, options?: QueryEncoderOptions) => string;
+export declare function queryEncoder(f: QueryEncoder): BulkQueryEncoder;
+export declare const encodeJSONQuery: BulkQueryEncoder;
+export declare const encodeFormQuery: BulkQueryEncoder;
+export declare const encodeSpaceDelimitedQuery: BulkQueryEncoder;
+export declare const encodePipeDelimitedQuery: BulkQueryEncoder;
+export declare const encodeDeepObjectQuery: BulkQueryEncoder;
+export {};
+//# sourceMappingURL=encodings.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/encodings.d.ts.map b/node_modules/@mistralai/mistralai/lib/encodings.d.ts.map
new file mode 100644
index 0000000000..c17b52785a
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/encodings.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"encodings.d.ts","sourceRoot":"","sources":["../src/lib/encodings.ts"],"names":[],"mappings":"AAOA,qBAAa,aAAc,SAAQ,KAAK;gBAC1B,OAAO,EAAE,MAAM;CAI5B;AAED,wBAAgB,YAAY,CAC1B,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,OAAO,EACd,OAAO,CAAC,EAAE;IAAE,OAAO,CAAC,EAAE,OAAO,CAAC;IAAC,YAAY,CAAC,EAAE,SAAS,GAAG,MAAM,CAAA;CAAE,GACjE,MAAM,CA4CR;AAED,wBAAgB,WAAW,CACzB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,OAAO,EACd,OAAO,CAAC,EAAE;IAAE,OAAO,CAAC,EAAE,OAAO,CAAC;IAAC,YAAY,CAAC,EAAE,SAAS,GAAG,MAAM,CAAA;CAAE,GACjE,MAAM,CAiCR;AAED,KAAK,WAAW,GAAG,CACjB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,OAAO,EACd,OAAO,CAA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G;IACzB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,YAAY,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC;CACnC,CAAC;AAEF,KAAK,YAAY,GAAG,CAClB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,OAAO,EACd,OAAO,CAAC,EAAE,mBAAmB,KAC1B,MAAM,CAAC;AAEZ,KAAK,gBAAgB,GAAG,CACtB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC/B,OAAO,CAAC,EAAE,mBAAmB,KAC1B,MAAM,CAAC;AAEZ,wBAAgB,YAAY,CAAC,CAAC,EAAE,YAAY,GAAG,gBAAgB,CAkB9D;AAED,eAAO,MAAM,eAAe,kBAA2B,CAAC;AACxD,eAAO,MAAM,eAAe,kBAA2B,CAAC;AACxD,eAAO,MAAM,yBAAyB,kBAAqC,CAAC;AAC5E,eAAO,MAAM,wBAAwB,kBAAoC,CAAC;AAC1E,eAAO,MAAM,qBAAqB,kBAAiC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/encodings.js b/node_modules/@mistralai/mistralai/lib/encodings.js
new file mode 100644
index 0000000000..bf1d5f004f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/encodings.js
@@ -0,0 +1,343 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.encodeDeepObjectQuery = exports.encodePipeDelimitedQuery = exports.encodeSpaceDelimitedQuery = exports.encodeFormQuery = exports.encodeJSONQuery = exports.encodeSimple = exports.encodePipeDelimited = exports.encodeSpaceDelimited = exports.encodeForm = exports.EncodingError = void 0;
+exports.encodeMatrix = encodeMatrix;
+exports.encodeLabel = encodeLabel;
+exports.encodeBodyForm = encodeBodyForm;
+exports.encodeDeepObject = encodeDeepObject;
+exports.encodeDeepObjectObject = encodeDeepObjectObject;
+exports.encodeJSON = encodeJSON;
+exports.queryJoin = queryJoin;
+exports.queryEncoder = queryEncoder;
+const base64_js_1 = require("./base64.js");
+const is_plain_object_js_1 = require("./is-plain-object.js");
+class EncodingError extends Error {
+ constructor(message) {
+ super(message);
+ this.name = "EncodingError";
+ }
+}
+exports.EncodingError = EncodingError;
+function encodeMatrix(key, value, options) {
+ let out = "";
+ const pairs = (options === null || options === void 0 ? void 0 : options.explode)
+ ? explode(key, value)
+ : [[key, value]];
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ const encodeValue = (v) => encodeString(serializeValue(v));
+ pairs.forEach(([pk, pv]) => {
+ let tmp = "";
+ let encValue = "";
+ if (pv === undefined) {
+ return;
+ }
+ else if (Array.isArray(pv)) {
+ encValue = mapDefined(pv, (v) => `${encodeValue(v)}`).join(",");
+ }
+ else if ((0, is_plain_object_js_1.isPlainObject)(pv)) {
+ encValue = mapDefinedEntries(Object.entries(pv), ([k, v]) => {
+ return `,${encodeString(k)},${encodeValue(v)}`;
+ }).join("");
+ encValue = encValue.slice(1);
+ }
+ else {
+ encValue = `${encodeValue(pv)}`;
+ }
+ const keyPrefix = encodeString(pk);
+ tmp = `${keyPrefix}=${encValue}`;
+ // trim trailing '=' if value was empty
+ if (tmp === `${keyPrefix}=`) {
+ tmp = tmp.slice(0, -1);
+ }
+ // If we end up with the nothing then skip forward
+ if (!tmp) {
+ return;
+ }
+ out += `;${tmp}`;
+ });
+ return out;
+}
+function encodeLabel(key, value, options) {
+ let out = "";
+ const pairs = (options === null || options === void 0 ? void 0 : options.explode)
+ ? explode(key, value)
+ : [[key, value]];
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ const encodeValue = (v) => encodeString(serializeValue(v));
+ pairs.forEach(([pk, pv]) => {
+ let encValue = "";
+ if (pv === undefined) {
+ return;
+ }
+ else if (Array.isArray(pv)) {
+ encValue = mapDefined(pv, (v) => `${encodeValue(v)}`).join(".");
+ }
+ else if ((0, is_plain_object_js_1.isPlainObject)(pv)) {
+ encValue = mapDefinedEntries(Object.entries(pv), ([k, v]) => {
+ return `.${encodeString(k)}.${encodeValue(v)}`;
+ }).join("");
+ encValue = encValue.slice(1);
+ }
+ else {
+ const k = (options === null || options === void 0 ? void 0 : options.explode) && (0, is_plain_object_js_1.isPlainObject)(value) ? `${encodeString(pk)}=` : "";
+ encValue = `${k}${encodeValue(pv)}`;
+ }
+ out += `.${encValue}`;
+ });
+ return out;
+}
+function formEncoder(sep) {
+ return (key, value, options) => {
+ let out = "";
+ const pairs = (options === null || options === void 0 ? void 0 : options.explode)
+ ? explode(key, value)
+ : [[key, value]];
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ const encodeValue = (v) => encodeString(serializeValue(v));
+ const encodedSep = encodeString(sep);
+ pairs.forEach(([pk, pv]) => {
+ let tmp = "";
+ let encValue = "";
+ if (pv === undefined) {
+ return;
+ }
+ else if (Array.isArray(pv)) {
+ encValue = mapDefined(pv, (v) => `${encodeValue(v)}`).join(encodedSep);
+ }
+ else if ((0, is_plain_object_js_1.isPlainObject)(pv)) {
+ encValue = mapDefinedEntries(Object.entries(pv), ([k, v]) => {
+ return `${encodeString(k)}${encodedSep}${encodeValue(v)}`;
+ }).join(encodedSep);
+ }
+ else {
+ encValue = `${encodeValue(pv)}`;
+ }
+ tmp = `${encodeString(pk)}=${encValue}`;
+ // If we end up with the nothing then skip forward
+ if (!tmp || tmp === "=") {
+ return;
+ }
+ out += `&${tmp}`;
+ });
+ return out.slice(1);
+ };
+}
+exports.encodeForm = formEncoder(",");
+exports.encodeSpaceDelimited = formEncoder(" ");
+exports.encodePipeDelimited = formEncoder("|");
+function encodeBodyForm(key, value, options) {
+ let out = "";
+ const pairs = (options === null || options === void 0 ? void 0 : options.explode)
+ ? explode(key, value)
+ : [[key, value]];
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ const encodeValue = (v) => encodeString(serializeValue(v));
+ pairs.forEach(([pk, pv]) => {
+ let tmp = "";
+ let encValue = "";
+ if (pv === undefined) {
+ return;
+ }
+ else if (Array.isArray(pv)) {
+ encValue = JSON.stringify(pv, jsonReplacer);
+ }
+ else if ((0, is_plain_object_js_1.isPlainObject)(pv)) {
+ encValue = JSON.stringify(pv, jsonReplacer);
+ }
+ else {
+ encValue = `${encodeValue(pv)}`;
+ }
+ tmp = `${encodeString(pk)}=${encValue}`;
+ // If we end up with the nothing then skip forward
+ if (!tmp || tmp === "=") {
+ return;
+ }
+ out += `&${tmp}`;
+ });
+ return out.slice(1);
+}
+function encodeDeepObject(key, value, options) {
+ if (value == null) {
+ return "";
+ }
+ if (!(0, is_plain_object_js_1.isPlainObject)(value)) {
+ throw new EncodingError(`Value of parameter '${key}' which uses deepObject encoding must be an object`);
+ }
+ return encodeDeepObjectObject(key, value, options);
+}
+function encodeDeepObjectObject(key, value, options) {
+ if (value == null) {
+ return "";
+ }
+ let out = "";
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ if (!(0, is_plain_object_js_1.isPlainObject)(value)) {
+ throw new EncodingError(`Expected parameter '${key}' to be an object.`);
+ }
+ Object.entries(value).forEach(([ck, cv]) => {
+ if (cv === undefined) {
+ return;
+ }
+ const pk = `${key}[${ck}]`;
+ if ((0, is_plain_object_js_1.isPlainObject)(cv)) {
+ const objOut = encodeDeepObjectObject(pk, cv, options);
+ out += `&${objOut}`;
+ return;
+ }
+ const pairs = Array.isArray(cv) ? cv : [cv];
+ let encoded = "";
+ encoded = mapDefined(pairs, (v) => {
+ return `${encodeString(pk)}=${encodeString(serializeValue(v))}`;
+ }).join("&");
+ out += `&${encoded}`;
+ });
+ return out.slice(1);
+}
+function encodeJSON(key, value, options) {
+ if (typeof value === "undefined") {
+ return "";
+ }
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ const encVal = encodeString(JSON.stringify(value, jsonReplacer));
+ return (options === null || options === void 0 ? void 0 : options.explode) ? encVal : `${encodeString(key)}=${encVal}`;
+}
+const encodeSimple = (key, value, options) => {
+ let out = "";
+ const pairs = (options === null || options === void 0 ? void 0 : options.explode)
+ ? explode(key, value)
+ : [[key, value]];
+ const encodeString = (v) => {
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent" ? encodeURIComponent(v) : v;
+ };
+ const encodeValue = (v) => encodeString(serializeValue(v));
+ pairs.forEach(([pk, pv]) => {
+ let tmp = "";
+ if (pv === undefined) {
+ return;
+ }
+ else if (Array.isArray(pv)) {
+ tmp = mapDefined(pv, (v) => `${encodeValue(v)}`).join(",");
+ }
+ else if ((0, is_plain_object_js_1.isPlainObject)(pv)) {
+ tmp = mapDefinedEntries(Object.entries(pv), ([k, v]) => {
+ return `,${encodeString(k)},${encodeValue(v)}`;
+ }).join("");
+ tmp = tmp.slice(1);
+ }
+ else {
+ const k = (options === null || options === void 0 ? void 0 : options.explode) && (0, is_plain_object_js_1.isPlainObject)(value) ? `${pk}=` : "";
+ tmp = `${k}${encodeValue(pv)}`;
+ }
+ // If we end up with the nothing then skip forward
+ if (!tmp) {
+ return;
+ }
+ out += `,${tmp}`;
+ });
+ return out.slice(1);
+};
+exports.encodeSimple = encodeSimple;
+function explode(key, value) {
+ if (Array.isArray(value)) {
+ return value.map((v) => [key, v]);
+ }
+ else if ((0, is_plain_object_js_1.isPlainObject)(value)) {
+ const o = value !== null && value !== void 0 ? value : {};
+ return Object.entries(o).map(([k, v]) => [k, v]);
+ }
+ else {
+ return [[key, value]];
+ }
+}
+function serializeValue(value) {
+ if (value === null) {
+ return "null";
+ }
+ else if (typeof value === "undefined") {
+ return "";
+ }
+ else if (value instanceof Date) {
+ return value.toISOString();
+ }
+ else if (value instanceof Uint8Array) {
+ return (0, base64_js_1.bytesToBase64)(value);
+ }
+ else if (typeof value === "object") {
+ return JSON.stringify(value, jsonReplacer);
+ }
+ return `${value}`;
+}
+function jsonReplacer(_, value) {
+ if (value instanceof Uint8Array) {
+ return (0, base64_js_1.bytesToBase64)(value);
+ }
+ else {
+ return value;
+ }
+}
+function mapDefined(inp, mapper) {
+ return inp.reduce((acc, v) => {
+ if (v === undefined) {
+ return acc;
+ }
+ const m = mapper(v);
+ if (m === undefined) {
+ return acc;
+ }
+ acc.push(m);
+ return acc;
+ }, []);
+}
+function mapDefinedEntries(inp, mapper) {
+ const acc = [];
+ for (const [k, v] of inp) {
+ if (v === undefined) {
+ continue;
+ }
+ const m = mapper([k, v]);
+ if (m === undefined) {
+ continue;
+ }
+ acc.push(m);
+ }
+ return acc;
+}
+function queryJoin(...args) {
+ return args.filter(Boolean).join("&");
+}
+function queryEncoder(f) {
+ const bulkEncode = function (values, options) {
+ var _a, _b;
+ const opts = {
+ ...options,
+ explode: (_a = options === null || options === void 0 ? void 0 : options.explode) !== null && _a !== void 0 ? _a : true,
+ charEncoding: (_b = options === null || options === void 0 ? void 0 : options.charEncoding) !== null && _b !== void 0 ? _b : "percent",
+ };
+ const encoded = Object.entries(values).map(([key, value]) => {
+ return f(key, value, opts);
+ });
+ return queryJoin(...encoded);
+ };
+ return bulkEncode;
+}
+exports.encodeJSONQuery = queryEncoder(encodeJSON);
+exports.encodeFormQuery = queryEncoder(exports.encodeForm);
+exports.encodeSpaceDelimitedQuery = queryEncoder(exports.encodeSpaceDelimited);
+exports.encodePipeDelimitedQuery = queryEncoder(exports.encodePipeDelimited);
+exports.encodeDeepObjectQuery = queryEncoder(encodeDeepObject);
+//# sourceMappingURL=encodings.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/encodings.js.map b/node_modules/@mistralai/mistralai/lib/encodings.js.map
new file mode 100644
index 0000000000..2b9291640f
--- /dev/null
+++ b/node_modules/@mistralai/mistral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,CAAE,YAAY,mCAAI,SAAS;SACjD,CAAC;QAEF,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,EAAE,KAAK,CAAC,EAAE,EAAE;YAC1D,OAAO,CAAC,CAAC,GAAG,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;QAC7B,CAAC,CAAC,CAAC;QACH,OAAO,SAAS,CAAC,GAAG,OAAO,CAAC,CAAC;IAC/B,CAAC,CAAC;IAEF,OAAO,UAAU,CAAC;AACpB,CAAC;AAEY,QAAA,eAAe,GAAG,YAAY,CAAC,UAAU,CAAC,CAAC;AAC3C,QAAA,eAAe,GAAG,YAAY,CAAC,kBAAU,CAAC,CAAC;AAC3C,QAAA,yBAAyB,GAAG,YAAY,CAAC,4BAAoB,CAAC,CAAC;AAC/D,QAAA,wBAAwB,GAAG,YAAY,CAAC,2BAAmB,CAAC,CAAC;AAC7D,QAAA,qBAAqB,GAAG,YAAY,CAAC,gBAAgB,CAAC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/env.d.ts b/node_modules/@mistralai/mistralai/lib/env.d.ts
new file mode 100644
index 0000000000..f4033923e5
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/env.d.ts
@@ -0,0 +1,15 @@
+import * as z from "zod";
+export interface Env {
+ MISTRAL_API_KEY?: string | undefined;
+ MISTRAL_DEBUG?: boolean | undefined;
+}
+export declare const envSchema: z.ZodType;
+/**
+ * Reads and validates environment variables.
+ */
+export declare function env(): Env;
+/**
+ * Clears the cached env object. Useful for testing with a fresh environment.
+ */
+export declare function resetEnv(): void;
+//# sourceMappingURL=env.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/env.d.ts.map b/node_modules/@mistralai/mistralai/lib/env.d.ts.map
new file mode 100644
index 0000000000..89c7bfaca6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/env.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"env.d.ts","sourceRoot":"","sources":["../src/lib/env.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,MAAM,WAAW,GAAG;IAClB,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAErC,aAAa,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;CACrC;AAED,eAAO,MAAM,SAAS,EAAE,CAAC,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,CAAC,UAAU,EAAE,OAAO,CAKhD,CAAC;AAGb;;GAEG;AACH,wBAAgB,GAAG,IAAI,GAAG,CASzB;AAED;;GAEG;AACH,wBAAgB,QAAQ,SAEvB"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/env.js b/node_modules/@mistralai/mistralai/lib/env.js
new file mode 100644
index 0000000000..425919e109
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/env.js
@@ -0,0 +1,57 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.envSchema = void 0;
+exports.env = env;
+exports.resetEnv = resetEnv;
+const dlv_js_1 = require("./dlv.js");
+const z = __importStar(require("zod"));
+exports.envSchema = z.object({
+ MISTRAL_API_KEY: z.string(),
+ MISTRAL_DEBUG: z.coerce.boolean(),
+})
+ .partial();
+let envMemo = undefined;
+/**
+ * Reads and validates environment variables.
+ */
+function env() {
+ var _a, _b;
+ if (envMemo) {
+ return envMemo;
+ }
+ envMemo = exports.envSchema.parse((_b = (_a = (0, dlv_js_1.dlv)(globalThis, "process.env")) !== null && _a !== void 0 ? _a : (0, dlv_js_1.dlv)(globalThis, "Deno.env")) !== null && _b !== void 0 ? _b : {});
+ return envMemo;
+}
+/**
+ * Clears the cached env object. Useful for testing with a fresh environment.
+ */
+function resetEnv() {
+ envMemo = undefined;
+}
+//# sourceMappingURL=env.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/env.js.map b/node_modules/@mistralai/mistralai/lib/env.js.map
new file mode 100644
index 0000000000..7418f44ed8
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/env.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"env.js","sourceRoot":"","sources":["../src/lib/env.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAuBH,kBASC;AAKD,4BAEC;AArCD,qCAA+B;AAE/B,uCAAyB;AAQZ,QAAA,SAAS,GAA0C,CAAC,CAAC,MAAM,CAAC;IACvE,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE;IAE3B,aAAa,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO,EAAE;CAClC,CAAC;KACC,OAAO,EAAE,CAAC;AAEb,IAAI,OAAO,GAAoB,SAAS,CAAC;AACzC;;GAEG;AACH,SAAgB,GAAG;;IACjB,IAAI,OAAO,EAAE,CAAC;QACZ,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,GAAG,iBAAS,CAAC,KAAK,CACvB,MAAA,MAAA,IAAA,YAAG,EAAC,UAAU,EAAE,aAAa,CAAC,mCAAI,IAAA,YAAG,EAAC,UAAU,EAAE,UAAU,CAAC,mCAAI,EAAE,CACpE,CAAC;IACF,OAAO,OAAO,CAAC;AACjB,CAAC;AAED;;GAEG;AACH,SAAgB,QAAQ;IACtB,OAAO,GAAG,SAAS,CAAC;AACtB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/event-streams.d.ts b/node_modules/@mistralai/mistralai/lib/event-streams.d.ts
new file mode 100644
index 0000000000..f4082f2aab
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/event-streams.d.ts
@@ -0,0 +1,17 @@
+export type ServerEvent = {
+ data?: T | undefined;
+ event?: string | undefined;
+ retry?: number | undefined;
+ id?: string | undefined;
+};
+export declare class EventStream> {
+ private readonly stream;
+ private readonly decoder;
+ constructor(init: {
+ stream: ReadableStream;
+ decoder: (rawEvent: ServerEvent) => Event;
+ });
+ [Symbol.asyncIterator](): AsyncGenerator;
+}
+export declare function discardSentinel(stream: ReadableStream, sentinel: string): ReadableStream;
+//# sourceMappingURL=event-streams.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/event-streams.d.ts.map b/node_modules/@mistralai/mistralai/lib/event-streams.d.ts.map
new file mode 100644
index 0000000000..5071d48fd8
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/event-streams.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"event-streams.d.ts","sourceRoot":"","sources":["../src/lib/event-streams.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,WAAW,CAAC,CAAC,IAAI;IAC3B,IAAI,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B,EAAE,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACzB,CAAC;AAUF,qBAAa,WAAW,CAAC,KAAK,SAAS,WAAW,CAAC,OAAO,CAAC;IACzD,OAAO,CAAC,QAAQ,CAAC,MAAM,CAA6B;IACpD,OAAO,CAAC,QAAQ,CAAC,OAAO,CAA2C;gBAEvD,IAAI,EAAE;QAChB,MAAM,EAAE,cAAc,CAAC,UAAU,CAAC,CAAC;QACnC,OAAO,EAAE,CAAC,QAAQ,EAAE,WAAW,CAAC,MAAM,CAAC,KAAK,KAAK,CAAC;KACnD;IAKM,CAAC,MAAM,CAAC,aAAa,CAAC,IAAI,cAAc,CAAC,KAAK,EAAE,IAAI,EAAE,OAAO,CAAC;CA+CtE;AAmHD,wBAAgB,eAAe,CAC7B,MAAM,EAAE,cAAc,CAAC,UAAU,CAAC,EAClC,QAAQ,EAAE,MAAM,GACf,cAAc,CAAC,UAAU,CAAC,CAyD5B"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/event-streams.js b/node_modules/@mistralai/mistralai/lib/event-streams.js
new file mode 100644
index 0000000000..8609a99555
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/event-streams.js
@@ -0,0 +1,215 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.EventStream = void 0;
+exports.discardSentinel = discardSentinel;
+const LF = 0x0a;
+const CR = 0x0d;
+const NEWLINE_CHARS = new Set([LF, CR]);
+const MESSAGE_BOUNDARIES = [
+ new Uint8Array([CR, LF, CR, LF]),
+ new Uint8Array([CR, CR]),
+ new Uint8Array([LF, LF]),
+];
+class EventStream {
+ constructor(init) {
+ this.stream = init.stream;
+ this.decoder = init.decoder;
+ }
+ async *[Symbol.asyncIterator]() {
+ const reader = this.stream.getReader();
+ let buffer = new Uint8Array([]);
+ let position = 0;
+ try {
+ while (true) {
+ const { done, value } = await reader.read();
+ if (done) {
+ break;
+ }
+ const newBuffer = new Uint8Array(buffer.length + value.length);
+ newBuffer.set(buffer);
+ newBuffer.set(value, buffer.length);
+ buffer = newBuffer;
+ for (let i = position; i < buffer.length; i++) {
+ const boundary = findBoundary(buffer, i);
+ if (boundary == null) {
+ continue;
+ }
+ const chunk = buffer.slice(position, i);
+ position = i + boundary.length;
+ const event = parseEvent(chunk, this.decoder);
+ if (event != null) {
+ yield event;
+ }
+ }
+ if (position > 0) {
+ buffer = buffer.slice(position);
+ position = 0;
+ }
+ }
+ if (buffer.length > 0) {
+ const event = parseEvent(buffer, this.decoder);
+ if (event != null) {
+ yield event;
+ }
+ }
+ }
+ finally {
+ reader.releaseLock();
+ }
+ }
+}
+exports.EventStream = EventStream;
+function findBoundary(buffer, start) {
+ const char1 = buffer[start];
+ const char2 = buffer[start + 1];
+ // Don't bother checking if the first two characters are not new line
+ // characters.
+ if (char1 == null
+ || char2 == null
+ || !NEWLINE_CHARS.has(char1)
+ || !NEWLINE_CHARS.has(char2)) {
+ return null;
+ }
+ for (const s of MESSAGE_BOUNDARIES) {
+ const seq = peekSequence(start, buffer, s);
+ if (seq != null) {
+ return seq;
+ }
+ }
+ return null;
+}
+function peekSequence(position, buffer, sequence) {
+ if (sequence.length > buffer.length - position) {
+ return null;
+ }
+ for (let i = 0; i < sequence.length; i++) {
+ if (buffer[position + i] !== sequence[i]) {
+ return null;
+ }
+ }
+ return sequence;
+}
+function parseEvent(chunk, decoder) {
+ var _a;
+ if (!chunk.length) {
+ return null;
+ }
+ const td = new TextDecoder();
+ const raw = td.decode(chunk);
+ const lines = raw.split(/\r?\n|\r/g);
+ let publish = false;
+ const rawEvent = {};
+ for (const line of lines) {
+ if (!line) {
+ continue;
+ }
+ const delim = line.indexOf(":");
+ // Lines starting with a colon are ignored.
+ if (delim === 0) {
+ continue;
+ }
+ const field = delim > 0 ? line.substring(0, delim) : "";
+ let value = delim > 0 ? line.substring(delim + 1) : "";
+ if (value.charAt(0) === " ") {
+ value = value.substring(1);
+ }
+ switch (field) {
+ case "event": {
+ publish = true;
+ rawEvent.event = value;
+ break;
+ }
+ case "data": {
+ publish = true;
+ (_a = rawEvent.data) !== null && _a !== void 0 ? _a : (rawEvent.data = "");
+ rawEvent.data += value + "\n";
+ break;
+ }
+ case "id": {
+ publish = true;
+ rawEvent.id = value;
+ break;
+ }
+ case "retry": {
+ const r = parseInt(value, 10);
+ if (!Number.isNaN(r)) {
+ publish = true;
+ rawEvent.retry = r;
+ }
+ break;
+ }
+ }
+ }
+ if (!publish) {
+ return null;
+ }
+ if (rawEvent.data != null) {
+ rawEvent.data = rawEvent.data.slice(0, -1);
+ }
+ return decoder(rawEvent);
+}
+function discardSentinel(stream, sentinel) {
+ return new ReadableStream({
+ async start(controller) {
+ let buffer = new Uint8Array([]);
+ let position = 0;
+ let done = false;
+ let discard = false;
+ const rdr = stream.getReader();
+ try {
+ while (!done) {
+ const result = await rdr.read();
+ const value = result.value;
+ done = done || result.done;
+ // We keep consuming from the source to its completion so it can
+ // flush all its contents and release resources.
+ if (discard) {
+ continue;
+ }
+ if (typeof value === "undefined") {
+ continue;
+ }
+ const newBuffer = new Uint8Array(buffer.length + value.length);
+ newBuffer.set(buffer);
+ newBuffer.set(value, buffer.length);
+ buffer = newBuffer;
+ for (let i = position; i < buffer.length; i++) {
+ const boundary = findBoundary(buffer, i);
+ if (boundary == null) {
+ continue;
+ }
+ const start = position;
+ const chunk = buffer.slice(start, i);
+ position = i + boundary.length;
+ const event = parseEvent(chunk, id);
+ if ((event === null || event === void 0 ? void 0 : event.data) === sentinel) {
+ controller.enqueue(buffer.slice(0, start));
+ discard = true;
+ }
+ else {
+ controller.enqueue(buffer.slice(0, position));
+ buffer = buffer.slice(position);
+ position = 0;
+ }
+ }
+ }
+ }
+ catch (e) {
+ controller.error(e);
+ }
+ finally {
+ // If the source stream terminates, flush its contents and terminate.
+ // If the sentinel event was found, flush everything up to its start.
+ controller.close();
+ rdr.releaseLock();
+ }
+ },
+ });
+}
+function id(v) {
+ return v;
+}
+//# sourceMappingURL=event-streams.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/event-streams.js.map b/node_modules/@mistralai/mistralai/lib/event-streams.js.map
new file mode 100644
index 0000000000..ee1349fce7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/event-streams.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"event-streams.js","sourceRoot":"","sources":["../src/lib/event-streams.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AA+LH,0CA4DC;AAnPD,MAAM,EAAE,GAAG,IAAI,CAAC;AAChB,MAAM,EAAE,GAAG,IAAI,CAAC;AAChB,MAAM,aAAa,GAAG,IAAI,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC,CAAC;AACxC,MAAM,kBAAkB,GAAG;IACzB,IAAI,UAAU,CAAC,CAAC,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IAChC,IAAI,UAAU,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;IACxB,IAAI,UAAU,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;CACzB,CAAC;AAEF,MAAa,WAAW;IAItB,YAAY,IAGX;QACC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;QAC1B,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC;IAC9B,CAAC;IAED,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC;QAC3B,MAAM,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC,SAAS,EAAE,CAAC;QACvC,IAAI,MAAM,GAAG,IAAI,UAAU,CAAC,EAAE,CAAC,CAAC;QAChC,IAAI,QAAQ,GAAG,CAAC,CAAC;QAEjB,IAAI,CAAC;YACH,OAAO,IAAI,EAAE,CAAC;gBACZ,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,MAAM,CAAC,IAAI,EAAE,CAAC;gBAC5C,IAAI,IAAI,EAAE,CAAC;oBAC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C,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC;4BAC3C,OAAO,GAAG,IAAI,CAAC;wBACjB,CAAC;6BAAM,CAAC;4BACN,UAAU,CAAC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC;4BAC9C,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC;4BAChC,QAAQ,GAAG,CAAC,CAAC;wBACf,CAAC;oBACH,CAAC;gBACH,CAAC;YACH,CAAC;YAAC,OAAO,CAAC,EAAE,CAAC;gBACX,UAAU,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;YACtB,CAAC;oBAAS,CAAC;gBACT,qEAAqE;gBACrE,qEAAqE;gBACrE,UAAU,CAAC,KAAK,EAAE,CAAC;gBACnB,GAAG,CAAC,WAAW,EAAE,CAAC;YACpB,CAAC;QACH,CAAC;KACF,CAAC,CAAC;AACL,CAAC;AAED,SAAS,EAAE,CAAI,CAAI;IACjB,OAAO,CAAC,CAAC;AACX,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/files.d.ts b/node_modules/@mistralai/mistralai/lib/files.d.ts
new file mode 100644
index 0000000000..730449a695
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/files.d.ts
@@ -0,0 +1,8 @@
+/**
+ * Consumes a stream and returns a concatenated array buffer. Useful in
+ * situations where we need to read the whole file because it forms part of a
+ * larger payload containing other fields, and we can't modify the underlying
+ * request structure.
+ */
+export declare function readableStreamToArrayBuffer(readable: ReadableStream): Promise;
+//# sourceMappingURL=files.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/files.d.ts.map b/node_modules/@mistralai/mistralai/lib/files.d.ts.map
new file mode 100644
index 0000000000..9f325b48a9
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/files.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"files.d.ts","sourceRoot":"","sources":["../src/lib/files.ts"],"names":[],"mappings":"AAIA;;;;;GAKG;AACH,wBAAsB,2BAA2B,CAC/C,QAAQ,EAAE,cAAc,CAAC,UAAU,CAAC,GACnC,OAAO,CAAC,WAAW,CAAC,CA2BtB"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/files.js b/node_modules/@mistralai/mistralai/lib/files.js
new file mode 100644
index 0000000000..70f27cadc2
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/files.js
@@ -0,0 +1,36 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.readableStreamToArrayBuffer = readableStreamToArrayBuffer;
+/**
+ * Consumes a stream and returns a concatenated array buffer. Useful in
+ * situations where we need to read the whole file because it forms part of a
+ * larger payload containing other fields, and we can't modify the underlying
+ * request structure.
+ */
+async function readableStreamToArrayBuffer(readable) {
+ const reader = readable.getReader();
+ const chunks = [];
+ let totalLength = 0;
+ let done = false;
+ while (!done) {
+ const { value, done: doneReading } = await reader.read();
+ if (doneReading) {
+ done = true;
+ }
+ else {
+ chunks.push(value);
+ totalLength += value.length;
+ }
+ }
+ const concatenatedChunks = new Uint8Array(totalLength);
+ let offset = 0;
+ for (const chunk of chunks) {
+ concatenatedChunks.set(chunk, offset);
+ offset += chunk.length;
+ }
+ return concatenatedChunks.buffer;
+}
+//# sourceMappingURL=files.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/files.js.map b/node_modules/@mistralai/mistralai/lib/files.js.map
new file mode 100644
index 0000000000..a8b407b689
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/files.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"files.js","sourceRoot":"","sources":["../src/lib/files.ts"],"names":[],"mappings":";AAAA;;GAEG;;AAQH,kEA6BC;AAnCD;;;;;GAKG;AACI,KAAK,UAAU,2BAA2B,CAC/C,QAAoC;IAEpC,MAAM,MAAM,GAAG,QAAQ,CAAC,SAAS,EAAE,CAAC;IACpC,MAAM,MAAM,GAAiB,EAAE,CAAC;IAEhC,IAAI,WAAW,GAAG,CAAC,CAAC;IACpB,IAAI,IAAI,GAAG,KAAK,CAAC;IAEjB,OAAO,CAAC,IAAI,EAAE,CAAC;QACb,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,WAAW,EAAE,GAAG,MAAM,MAAM,CAAC,IAAI,EAAE,CAAC;QAEzD,IAAI,WAAW,EAAE,CAAC;YAChB,IAAI,GAAG,IAAI,CAAC;QACd,CAAC;aAAM,CAAC;YACN,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YACnB,WAAW,IAAI,KAAK,CAAC,MAAM,CAAC;QAC9B,CAAC;IACH,CAAC;IAED,MAAM,kBAAkB,GAAG,IAAI,UAAU,CAAC,WAAW,CAAC,CAAC;IACvD,IAAI,MAAM,GAAG,CAAC,CAAC;IAEf,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;QAC3B,kBAAkB,CAAC,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;QACtC,MAAM,IAAI,KAAK,CAAC,MAAM,CAAC;IACzB,CAAC;IAED,OAAO,kBAAkB,CAAC,MAAM,CAAC;AACnC,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/http.d.ts b/node_modules/@mistralai/mistralai/lib/http.d.ts
new file mode 100644
index 0000000000..2c44bb6fb1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/http.d.ts
@@ -0,0 +1,67 @@
+export type Fetcher = (input: RequestInfo | URL, init?: RequestInit) => Promise;
+export type Awaitable = T | Promise;
+export type RequestInput = {
+ /**
+ * The URL the request will use.
+ */
+ url: URL;
+ /**
+ * Options used to create a [`Request`](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request).
+ */
+ options?: RequestInit | undefined;
+};
+export interface HTTPClientOptions {
+ fetcher?: Fetcher;
+}
+export type BeforeRequestHook = (req: Request) => Awaitable;
+export type RequestErrorHook = (err: unknown, req: Request) => Awaitable;
+export type ResponseHook = (res: Response, req: Request) => Awaitable;
+export declare class HTTPClient {
+ private options;
+ private fetcher;
+ private requestHooks;
+ private requestErrorHooks;
+ private responseHooks;
+ constructor(options?: HTTPClientOptions);
+ request(request: Request): Promise;
+ /**
+ * Registers a hook that is called before a request is made. The hook function
+ * can mutate the request or return a new request. This may be useful to add
+ * additional information to request such as request IDs and tracing headers.
+ */
+ addHook(hook: "beforeRequest", fn: BeforeRequestHook): this;
+ /**
+ * Registers a hook that is called when a request cannot be made due to a
+ * network error.
+ */
+ addHook(hook: "requestError", fn: RequestErrorHook): this;
+ /**
+ * Registers a hook that is called when a response has been received from the
+ * server.
+ */
+ addHook(hook: "response", fn: ResponseHook): this;
+ /** Removes a hook that was previously registered with `addHook`. */
+ removeHook(hook: "beforeRequest", fn: BeforeRequestHook): this;
+ /** Removes a hook that was previously registered with `addHook`. */
+ removeHook(hook: "requestError", fn: RequestErrorHook): this;
+ /** Removes a hook that was previously registered with `addHook`. */
+ removeHook(hook: "response", fn: ResponseHook): this;
+ clone(): HTTPClient;
+}
+export type StatusCodePredicate = number | string | (number | string)[];
+export declare function matchContentType(response: Response, pattern: string): boolean;
+export declare function matchStatusCode(response: Response, codes: StatusCodePredicate): boolean;
+export declare function matchResponse(response: Response, code: StatusCodePredicate, contentTypePattern: string): boolean;
+/**
+ * Uses various heurisitics to determine if an error is a connection error.
+ */
+export declare function isConnectionError(err: unknown): boolean;
+/**
+ * Uses various heurisitics to determine if an error is a timeout error.
+ */
+export declare function isTimeoutError(err: unknown): boolean;
+/**
+ * Uses various heurisitics to determine if an error is a abort error.
+ */
+export declare function isAbortError(err: unknown): boolean;
+//# sourceMappingURL=http.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/http.d.ts.map b/node_modules/@mistralai/mistralai/lib/http.d.ts.map
new file mode 100644
index 0000000000..0b11fa1fc5
--- /d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AAE,iBAAiB,GAAG,IAAI;IAC3D;;;OAGG;IACH,OAAO,CAAC,IAAI,EAAE,cAAc,EAAE,EAAE,EAAE,gBAAgB,GAAG,IAAI;IACzD;;;OAGG;IACH,OAAO,CAAC,IAAI,EAAE,UAAU,EAAE,EAAE,EAAE,YAAY,GAAG,IAAI;IAmBjD,oEAAoE;IACpE,UAAU,CAAC,IAAI,EAAE,eAAe,EAAE,EAAE,EAAE,iBAAiB,GAAG,IAAI;IAC9D,oEAAoE;IACpE,UAAU,CAAC,IAAI,EAAE,cAAc,EAAE,EAAE,EAAE,gBAAgB,GAAG,IAAI;IAC5D,oEAAoE;IACpE,UAAU,CAAC,IAAI,EAAE,UAAU,EAAE,EAAE,EAAE,YAAY,GAAG,IAAI;IA0BpD,KAAK,IAAI,UAAU;CAQpB;AAED,MAAM,MAAM,mBAAmB,GAAG,MAAM,GAAG,MAAM,GAAG,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,CAAC;AAMxE,wBAAgB,gBAAgB,CAAC,QAAQ,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CA8C7E;AAID,wBAAgB,eAAe,CAC7B,QAAQ,EAAE,QAAQ,EAClB,KAAK,EAAE,mBAAmB,GACzB,OAAO,CA8BT;AAED,wBAAgB,aAAa,CAC3B,QAAQ,EAAE,QAAQ,EAClB,IAAI,EAAE,mBAAmB,EACzB,kBAAkB,EAAE,MAAM,GACzB,OAAO,CAKT;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAsBvD;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAgBpD;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,OAAO,GAAG,OAAO,CAgBlD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/http.js b/node_modules/@mistralai/mistralai/lib/http.js
new file mode 100644
index 0000000000..0a0bbc3ea7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/http.js
@@ -0,0 +1,218 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.HTTPClient = void 0;
+exports.matchContentType = matchContentType;
+exports.matchStatusCode = matchStatusCode;
+exports.matchResponse = matchResponse;
+exports.isConnectionError = isConnectionError;
+exports.isTimeoutError = isTimeoutError;
+exports.isAbortError = isAbortError;
+const DEFAULT_FETCHER = (input, init) => {
+ // If input is a Request and init is undefined, Bun will discard the method,
+ // headers, body and other options that were set on the request object.
+ // Node.js and browers would ignore an undefined init value. This check is
+ // therefore needed for interop with Bun.
+ if (init == null) {
+ return fetch(input);
+ }
+ else {
+ return fetch(input, init);
+ }
+};
+class HTTPClient {
+ constructor(options = {}) {
+ this.options = options;
+ this.requestHooks = [];
+ this.requestErrorHooks = [];
+ this.responseHooks = [];
+ this.fetcher = options.fetcher || DEFAULT_FETCHER;
+ }
+ async request(request) {
+ let req = request;
+ for (const hook of this.requestHooks) {
+ const nextRequest = await hook(req);
+ if (nextRequest) {
+ req = nextRequest;
+ }
+ }
+ try {
+ const res = await this.fetcher(req);
+ for (const hook of this.responseHooks) {
+ await hook(res, req);
+ }
+ return res;
+ }
+ catch (err) {
+ for (const hook of this.requestErrorHooks) {
+ await hook(err, req);
+ }
+ throw err;
+ }
+ }
+ addHook(...args) {
+ if (args[0] === "beforeRequest") {
+ this.requestHooks.push(args[1]);
+ }
+ else if (args[0] === "requestError") {
+ this.requestErrorHooks.push(args[1]);
+ }
+ else if (args[0] === "response") {
+ this.responseHooks.push(args[1]);
+ }
+ else {
+ throw new Error(`Invalid hook type: ${args[0]}`);
+ }
+ return this;
+ }
+ removeHook(...args) {
+ let target;
+ if (args[0] === "beforeRequest") {
+ target = this.requestHooks;
+ }
+ else if (args[0] === "requestError") {
+ target = this.requestErrorHooks;
+ }
+ else if (args[0] === "response") {
+ target = this.responseHooks;
+ }
+ else {
+ throw new Error(`Invalid hook type: ${args[0]}`);
+ }
+ const index = target.findIndex((v) => v === args[1]);
+ if (index >= 0) {
+ target.splice(index, 1);
+ }
+ return this;
+ }
+ clone() {
+ const child = new HTTPClient(this.options);
+ child.requestHooks = this.requestHooks.slice();
+ child.requestErrorHooks = this.requestErrorHooks.slice();
+ child.responseHooks = this.responseHooks.slice();
+ return child;
+ }
+}
+exports.HTTPClient = HTTPClient;
+// A semicolon surrounded by optional whitespace characters is used to separate
+// segments in a media type string.
+const mediaParamSeparator = /\s*;\s*/g;
+function matchContentType(response, pattern) {
+ var _a;
+ // `*` is a special case which means anything is acceptable.
+ if (pattern === "*") {
+ return true;
+ }
+ let contentType = ((_a = response.headers.get("content-type")) === null || _a === void 0 ? void 0 : _a.trim()) || "application/octet-stream";
+ contentType = contentType.toLowerCase();
+ const wantParts = pattern.toLowerCase().trim().split(mediaParamSeparator);
+ const [wantType = "", ...wantParams] = wantParts;
+ if (wantType.split("/").length !== 2) {
+ return false;
+ }
+ const gotParts = contentType.split(mediaParamSeparator);
+ const [gotType = "", ...gotParams] = gotParts;
+ const [type = "", subtype = ""] = gotType.split("/");
+ if (!type || !subtype) {
+ return false;
+ }
+ if (wantType !== "*/*" &&
+ gotType !== wantType &&
+ `${type}/*` !== wantType &&
+ `*/${subtype}` !== wantType) {
+ return false;
+ }
+ if (gotParams.length < wantParams.length) {
+ return false;
+ }
+ const params = new Set(gotParams);
+ for (const wantParam of wantParams) {
+ if (!params.has(wantParam)) {
+ return false;
+ }
+ }
+ return true;
+}
+const codeRangeRE = new RegExp("^[0-9]xx$", "i");
+function matchStatusCode(response, codes) {
+ const actual = `${response.status}`;
+ const expectedCodes = Array.isArray(codes) ? codes : [codes];
+ if (!expectedCodes.length) {
+ return false;
+ }
+ return expectedCodes.some((ec) => {
+ const code = `${ec}`;
+ if (code === "default") {
+ return true;
+ }
+ if (!codeRangeRE.test(`${code}`)) {
+ return code === actual;
+ }
+ const expectFamily = code.charAt(0);
+ if (!expectFamily) {
+ throw new Error("Invalid status code range");
+ }
+ const actualFamily = actual.charAt(0);
+ if (!actualFamily) {
+ throw new Error(`Invalid response status code: ${actual}`);
+ }
+ return actualFamily === expectFamily;
+ });
+}
+function matchResponse(response, code, contentTypePattern) {
+ return (matchStatusCode(response, code) &&
+ matchContentType(response, contentTypePattern));
+}
+/**
+ * Uses various heurisitics to determine if an error is a connection error.
+ */
+function isConnectionError(err) {
+ if (typeof err !== "object" || err == null) {
+ return false;
+ }
+ // Covers fetch in Deno as well
+ const isBrowserErr = err instanceof TypeError &&
+ err.message.toLowerCase().startsWith("failed to fetch");
+ const isNodeErr = err instanceof TypeError &&
+ err.message.toLowerCase().startsWith("fetch failed");
+ const isBunErr = "name" in err && err.name === "ConnectionError";
+ const isGenericErr = "code" in err &&
+ typeof err.code === "string" &&
+ err.code.toLowerCase() === "econnreset";
+ return isBrowserErr || isNodeErr || isGenericErr || isBunErr;
+}
+/**
+ * Uses various heurisitics to determine if an error is a timeout error.
+ */
+function isTimeoutError(err) {
+ if (typeof err !== "object" || err == null) {
+ return false;
+ }
+ // Fetch in browser, Node.js, Bun, Deno
+ const isNative = "name" in err && err.name === "TimeoutError";
+ const isLegacyNative = "code" in err && err.code === 23;
+ // Node.js HTTP client and Axios
+ const isGenericErr = "code" in err &&
+ typeof err.code === "string" &&
+ err.code.toLowerCase() === "econnaborted";
+ return isNative || isLegacyNative || isGenericErr;
+}
+/**
+ * Uses various heurisitics to determine if an error is a abort error.
+ */
+function isAbortError(err) {
+ if (typeof err !== "object" || err == null) {
+ return false;
+ }
+ // Fetch in browser, Node.js, Bun, Deno
+ const isNative = "name" in err && err.name === "AbortError";
+ const isLegacyNative = "code" in err && err.code === 20;
+ // Node.js HTTP client and Axios
+ const isGenericErr = "code" in err &&
+ typeof err.code === "string" &&
+ err.code.toLowerCase() === "econnaborted";
+ return isNative || isLegacyNative || isGenericErr;
+}
+//# sourceMappingURL=http.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/http.js.map b/node_modules/@mistralai/mistralai/lib/http.js.map
new file mode 100644
index 0000000000..783d5bd7c6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/http.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"http.js","sourceRoot":"","sources":["../src/lib/http.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AA6JH,4CA8CC;AAID,0CAiCC;AAED,sCASC;AAKD,8CAsBC;AAKD,wCAgBC;AAKD,oCAgBC;AAvTD,MAAM,eAAe,GAAY,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE;IAC/C,4EAA4E;IAC5E,uEAAuE;IACvE,0EAA0E;IAC1E,yCAAyC;IACzC,IAAI,IAAI,IAAI,IAAI,EAAE,CAAC;QACjB,OAAO,KAAK,CAAC,KAAK,CAAC,CAAC;IACtB,CAAC;SAAM,CAAC;QACN,OAAO,KAAK,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;IAC5B,CAAC;AACH,CAAC,CAAC;AAqBF,MAAa,UAAU;IAMrB,YAAoB,UAA6B,EAAE;QAA/B,YAAO,GAAP,OAAO,CAAwB;QAJ3C,iBAAY,GAAwB,EAAE,CAAC;QACvC,sBAAiB,GAAuB,EAAE,CAAC;QAC3C,kBAAa,GAAmB,EAAE,CAAC;QAGzC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC,OAAO,IAAI,eAAe,CAAC;IACpD,CAAC;IAED,KAAK,CAAC,OAAO,CAAC,OAAgB;QAC5B,IAAI,GAAG,GAAG,OAAO,CAAC;QAClB,KAAK,MAAM,IAAI,IAAI,IAAI,CAAC,YAAY,EAAE,CAAC;YACrC,MAAM,WAAW,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,CAAC;YACpC,IAAI,WAAW,EAAE,CAAC;gBAChB,GAAG,GAAG,WAAW,CAAC;YACpB,CAAC;QACH,CAAC;QAED,IAAI,CAAC;YACH,MAAM,GAAG,GAAG,MAAM,IAAI,CAAC,O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AO,GAAG,CAAC,IAAI,KAAK,QAAQ;QAC5B,GAAG,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,cAAc,CAAC;IAE5C,OAAO,QAAQ,IAAI,cAAc,IAAI,YAAY,CAAC;AACpD,CAAC;AAED;;GAEG;AACH,SAAgB,YAAY,CAAC,GAAY;IACvC,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAC3C,OAAO,KAAK,CAAC;IACf,CAAC;IAED,uCAAuC;IACvC,MAAM,QAAQ,GAAG,MAAM,IAAI,GAAG,IAAI,GAAG,CAAC,IAAI,KAAK,YAAY,CAAC;IAC5D,MAAM,cAAc,GAAG,MAAM,IAAI,GAAG,IAAI,GAAG,CAAC,IAAI,KAAK,EAAE,CAAC;IAExD,gCAAgC;IAChC,MAAM,YAAY,GAChB,MAAM,IAAI,GAAG;QACb,OAAO,GAAG,CAAC,IAAI,KAAK,QAAQ;QAC5B,GAAG,CAAC,IAAI,CAAC,WAAW,EAAE,KAAK,cAAc,CAAC;IAE5C,OAAO,QAAQ,IAAI,cAAc,IAAI,YAAY,CAAC;AACpD,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/is-plain-object.d.ts b/node_modules/@mistralai/mistralai/lib/is-plain-object.d.ts
new file mode 100644
index 0000000000..a3f1ab34dc
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/is-plain-object.d.ts
@@ -0,0 +1,2 @@
+export declare function isPlainObject(value: unknown): value is object;
+//# sourceMappingURL=is-plain-object.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/is-plain-object.d.ts.map b/node_modules/@mistralai/mistralai/lib/is-plain-object.d.ts.map
new file mode 100644
index 0000000000..044ff3f1a1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/is-plain-object.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-plain-object.d.ts","sourceRoot":"","sources":["../src/lib/is-plain-object.ts"],"names":[],"mappings":"AA6BA,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,MAAM,CAa7D"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/is-plain-object.js b/node_modules/@mistralai/mistralai/lib/is-plain-object.js
new file mode 100644
index 0000000000..b30c5de166
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/is-plain-object.js
@@ -0,0 +1,41 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.isPlainObject = isPlainObject;
+/*
+MIT License
+
+Copyright (c) Sindre Sorhus (https://sindresorhus.com)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
+// Taken from https://github.com/sindresorhus/is-plain-obj/blob/97f38e8836f86a642cce98fc6ab3058bc36df181/index.js
+function isPlainObject(value) {
+ if (typeof value !== "object" || value === null) {
+ return false;
+ }
+ const prototype = Object.getPrototypeOf(value);
+ return ((prototype === null ||
+ prototype === Object.prototype ||
+ Object.getPrototypeOf(prototype) === null) &&
+ !(Symbol.toStringTag in value) &&
+ !(Symbol.iterator in value));
+}
+//# sourceMappingURL=is-plain-object.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/is-plain-object.js.map b/node_modules/@mistralai/mistralai/lib/is-plain-object.js.map
new file mode 100644
index 0000000000..8a36edc2ba
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/is-plain-object.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"is-plain-object.js","sourceRoot":"","sources":["../src/lib/is-plain-object.ts"],"names":[],"mappings":";AAAA;;GAEG;;AA2BH,sCAaC;AAtCD;;;;;;;;;;;;;;;;;;;;;EAqBE;AAEF,iHAAiH;AAEjH,SAAgB,aAAa,CAAC,KAAc;IAC1C,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QAChD,OAAO,KAAK,CAAC;IACf,CAAC;IAED,MAAM,SAAS,GAAG,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;IAC/C,OAAO,CACL,CAAC,SAAS,KAAK,IAAI;QACjB,SAAS,KAAK,MAAM,CAAC,SAAS;QAC9B,MAAM,CAAC,cAAc,CAAC,SAAS,CAAC,KAAK,IAAI,CAAC;QAC5C,CAAC,CAAC,MAAM,CAAC,WAAW,IAAI,KAAK,CAAC;QAC9B,CAAC,CAAC,MAAM,CAAC,QAAQ,IAAI,KAAK,CAAC,CAC5B,CAAC;AACJ,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/logger.d.ts b/node_modules/@mistralai/mistralai/lib/logger.d.ts
new file mode 100644
index 0000000000..12d31d0e0b
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/logger.d.ts
@@ -0,0 +1,6 @@
+export interface Logger {
+ group(label?: string): void;
+ groupEnd(): void;
+ log(message: any, ...args: any[]): void;
+}
+//# sourceMappingURL=logger.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/logger.d.ts.map b/node_modules/@mistralai/mistralai/lib/logger.d.ts.map
new file mode 100644
index 0000000000..5c05da0966
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/logger.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../src/lib/logger.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,MAAM;IACrB,KAAK,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,QAAQ,IAAI,IAAI,CAAC;IACjB,GAAG,CAAC,OAAO,EAAE,GAAG,EAAE,GAAG,IAAI,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;CACzC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/logger.js b/node_modules/@mistralai/mistralai/lib/logger.js
new file mode 100644
index 0000000000..d649599a1b
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/logger.js
@@ -0,0 +1,6 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+//# sourceMappingURL=logger.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/logger.js.map b/node_modules/@mistralai/mistralai/lib/logger.js.map
new file mode 100644
index 0000000000..ad150ca39b
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/logger.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"logger.js","sourceRoot":"","sources":["../src/lib/logger.ts"],"names":[],"mappings":";AAAA;;GAEG"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/matchers.d.ts b/node_modules/@mistralai/mistralai/lib/matchers.d.ts
new file mode 100644
index 0000000000..2ea3beebd1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/matchers.d.ts
@@ -0,0 +1,64 @@
+import { SDKError } from "../models/errors/sdkerror.js";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+import { StatusCodePredicate } from "./http.js";
+export type Encoding = "json" | "text" | "bytes" | "stream" | "sse" | "nil" | "fail";
+type Schema = {
+ parse(raw: unknown): T;
+};
+type MatchOptions = {
+ ctype?: string;
+ hdrs?: boolean;
+ key?: string;
+ sseSentinel?: string;
+};
+export type ValueMatcher = MatchOptions & {
+ enc: Encoding;
+ codes: StatusCodePredicate;
+ schema: Schema;
+};
+export type ErrorMatcher = MatchOptions & {
+ enc: Encoding;
+ codes: StatusCodePredicate;
+ schema: Schema;
+ err: true;
+};
+export type FailMatcher = {
+ enc: "fail";
+ codes: StatusCodePredicate;
+};
+export type Matcher = ValueMatcher | ErrorMatcher | FailMatcher;
+export declare function jsonErr(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ErrorMatcher;
+export declare function json(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ValueMatcher;
+export declare function textErr(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ErrorMatcher;
+export declare function text(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ValueMatcher;
+export declare function bytesErr(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ErrorMatcher;
+export declare function bytes(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ValueMatcher;
+export declare function streamErr(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ErrorMatcher;
+export declare function stream(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ValueMatcher;
+export declare function sseErr(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ErrorMatcher;
+export declare function sse(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ValueMatcher;
+export declare function nilErr(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ErrorMatcher;
+export declare function nil(codes: StatusCodePredicate, schema: Schema, options?: MatchOptions): ValueMatcher;
+export declare function fail(codes: StatusCodePredicate): FailMatcher;
+export type MatchedValue = Matchers extends Matcher[] ? T : never;
+export type MatchedError = Matchers extends Matcher[] ? E : never;
+export type MatchFunc = (response: Response, options?: {
+ resultKey?: string;
+ extraFields?: Record;
+}) => Promise<[result: Result, raw: unknown]>;
+export declare function match(...matchers: Array>): MatchFunc;
+/**
+ * Iterates over a Headers object and returns an object with all the header
+ * entries. Values are represented as an array to account for repeated headers.
+ */
+export declare function unpackHeaders(headers: Headers): Record;
+/**
+ * Discards the response body to free up resources.
+ *
+ * To learn why this is need, see the undici docs:
+ * https://undici.nodejs.org/#/?id=garbage-collection
+ */
+export declare function discardResponseBody(res: Response): Promise;
+export {};
+//# sourceMappingURL=matchers.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/matchers.d.ts.map b/node_modules/@mistralai/mistralai/lib/matchers.d.ts.map
new file mode 100644
index 0000000000..bba98068f6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/matchers.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"matchers.d.ts","sourceRoot":"","sources":["../src/lib/matchers.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC,OAAO,EAAkC,mBAAmB,EAAE,MAAM,WAAW,CAAC;AAIhF,MAAM,MAAM,QAAQ,GAChB,MAAM,GACN,MAAM,GACN,OAAO,GACP,QAAQ,GACR,KAAK,GACL,KAAK,GACL,MAAM,CAAC;AAYX,KAAK,MAAM,CAAC,CAAC,IAAI;IAAE,KAAK,CAAC,GAAG,EAAE,OAAO,GAAG,CAAC,CAAA;CAAE,CAAC;AAE5C,KAAK,YAAY,GAAG;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,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\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/matchers.js b/node_modules/@mistralai/mistralai/lib/matchers.js
new file mode 100644
index 0000000000..24068dfee3
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/matchers.js
@@ -0,0 +1,208 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.jsonErr = jsonErr;
+exports.json = json;
+exports.textErr = textErr;
+exports.text = text;
+exports.bytesErr = bytesErr;
+exports.bytes = bytes;
+exports.streamErr = streamErr;
+exports.stream = stream;
+exports.sseErr = sseErr;
+exports.sse = sse;
+exports.nilErr = nilErr;
+exports.nil = nil;
+exports.fail = fail;
+exports.match = match;
+exports.unpackHeaders = unpackHeaders;
+exports.discardResponseBody = discardResponseBody;
+const sdkerror_js_1 = require("../models/errors/sdkerror.js");
+const event_streams_js_1 = require("./event-streams.js");
+const http_js_1 = require("./http.js");
+const is_plain_object_js_1 = require("./is-plain-object.js");
+const schemas_js_1 = require("./schemas.js");
+const DEFAULT_CONTENT_TYPES = {
+ json: "application/json",
+ text: "text/plain",
+ bytes: "application/octet-stream",
+ stream: "application/octet-stream",
+ sse: "text/event-stream",
+ nil: "*",
+ fail: "*",
+};
+function jsonErr(codes, schema, options) {
+ return { ...options, err: true, enc: "json", codes, schema };
+}
+function json(codes, schema, options) {
+ return { ...options, enc: "json", codes, schema };
+}
+function textErr(codes, schema, options) {
+ return { ...options, err: true, enc: "text", codes, schema };
+}
+function text(codes, schema, options) {
+ return { ...options, enc: "text", codes, schema };
+}
+function bytesErr(codes, schema, options) {
+ return { ...options, err: true, enc: "bytes", codes, schema };
+}
+function bytes(codes, schema, options) {
+ return { ...options, enc: "bytes", codes, schema };
+}
+function streamErr(codes, schema, options) {
+ return { ...options, err: true, enc: "stream", codes, schema };
+}
+function stream(codes, schema, options) {
+ return { ...options, enc: "stream", codes, schema };
+}
+function sseErr(codes, schema, options) {
+ return { ...options, err: true, enc: "sse", codes, schema };
+}
+function sse(codes, schema, options) {
+ return { ...options, enc: "sse", codes, schema };
+}
+function nilErr(codes, schema, options) {
+ return { ...options, err: true, enc: "nil", codes, schema };
+}
+function nil(codes, schema, options) {
+ return { ...options, enc: "nil", codes, schema };
+}
+function fail(codes) {
+ return { enc: "fail", codes };
+}
+function match(...matchers) {
+ return async function matchFunc(response, options) {
+ let raw;
+ let matcher;
+ for (const match of matchers) {
+ const { codes } = match;
+ const ctpattern = "ctype" in match
+ ? match.ctype
+ : DEFAULT_CONTENT_TYPES[match.enc];
+ if (ctpattern && (0, http_js_1.matchResponse)(response, codes, ctpattern)) {
+ matcher = match;
+ break;
+ }
+ else if (!ctpattern && (0, http_js_1.matchStatusCode)(response, codes)) {
+ matcher = match;
+ break;
+ }
+ }
+ if (!matcher) {
+ const responseBody = await response.text();
+ return [{
+ ok: false,
+ error: new sdkerror_js_1.SDKError("Unexpected API response status or content-type", response, responseBody),
+ }, responseBody];
+ }
+ const encoding = matcher.enc;
+ switch (encoding) {
+ case "json":
+ raw = await response.json();
+ break;
+ case "bytes":
+ raw = await response.arrayBuffer();
+ break;
+ case "stream":
+ raw = response.body;
+ break;
+ case "text":
+ raw = await response.text();
+ break;
+ case "sse":
+ raw = response.body && matcher.sseSentinel
+ ? (0, event_streams_js_1.discardSentinel)(response.body, matcher.sseSentinel)
+ : response.body;
+ break;
+ case "nil":
+ raw = await discardResponseBody(response);
+ break;
+ case "fail":
+ raw = await response.text();
+ break;
+ default:
+ encoding;
+ throw new Error(`Unsupported response type: ${encoding}`);
+ }
+ if (matcher.enc === "fail") {
+ return [{
+ ok: false,
+ error: new sdkerror_js_1.SDKError("API error occurred", response, typeof raw === "string" ? raw : ""),
+ }, raw];
+ }
+ const resultKey = matcher.key || (options === null || options === void 0 ? void 0 : options.resultKey);
+ let data;
+ if ("err" in matcher) {
+ data = {
+ ...options === null || options === void 0 ? void 0 : options.extraFields,
+ ...(matcher.hdrs ? { Headers: unpackHeaders(response.headers) } : null),
+ ...((0, is_plain_object_js_1.isPlainObject)(raw) ? raw : null),
+ };
+ }
+ else if (resultKey) {
+ data = {
+ ...options === null || options === void 0 ? void 0 : options.extraFields,
+ ...(matcher.hdrs ? { Headers: unpackHeaders(response.headers) } : null),
+ [resultKey]: raw,
+ };
+ }
+ else if (matcher.hdrs) {
+ data = {
+ ...options === null || options === void 0 ? void 0 : options.extraFields,
+ ...(matcher.hdrs ? { Headers: unpackHeaders(response.headers) } : null),
+ ...((0, is_plain_object_js_1.isPlainObject)(raw) ? raw : null),
+ };
+ }
+ else {
+ data = raw;
+ }
+ if ("err" in matcher) {
+ const result = (0, schemas_js_1.safeParse)(data, (v) => matcher.schema.parse(v), "Response validation failed");
+ return [result.ok ? { ok: false, error: result.value } : result, raw];
+ }
+ else {
+ return [
+ (0, schemas_js_1.safeParse)(data, (v) => matcher.schema.parse(v), "Response validation failed"),
+ raw,
+ ];
+ }
+ };
+}
+const headerValRE = /, */;
+/**
+ * Iterates over a Headers object and returns an object with all the header
+ * entries. Values are represented as an array to account for repeated headers.
+ */
+function unpackHeaders(headers) {
+ const out = {};
+ for (const [k, v] of headers.entries()) {
+ out[k] = v.split(headerValRE);
+ }
+ return out;
+}
+/**
+ * Discards the response body to free up resources.
+ *
+ * To learn why this is need, see the undici docs:
+ * https://undici.nodejs.org/#/?id=garbage-collection
+ */
+async function discardResponseBody(res) {
+ var _a;
+ const reader = (_a = res.body) === null || _a === void 0 ? void 0 : _a.getReader();
+ if (reader == null) {
+ return;
+ }
+ try {
+ let done = false;
+ while (!done) {
+ const res = await reader.read();
+ done = res.done;
+ }
+ }
+ finally {
+ reader.releaseLock();
+ }
+}
+//# sourceMappingURL=matchers.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/matchers.js.map b/node_modules/@mistralai/mistralai/lib/matchers.js.map
new file mode 100644
index 0000000000..295e28ccc7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/matchers.js.map
@@ -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CAAC;QACjB,OAAO,CAAC,IAAI,EAAE,CAAC;YACb,MAAM,GAAG,GAAG,MAAM,MAAM,CAAC,IAAI,EAAE,CAAC;YAChC,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;QAClB,CAAC;IACH,CAAC;YAAS,CAAC;QACT,MAAM,CAAC,WAAW,EAAE,CAAC;IACvB,CAAC;AACH,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/primitives.d.ts b/node_modules/@mistralai/mistralai/lib/primitives.d.ts
new file mode 100644
index 0000000000..15659ece99
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/primitives.d.ts
@@ -0,0 +1,16 @@
+export type Remap = {
+ [k in keyof Inp as Mapping[k] extends string ? Mapping[k] : Mapping[k] extends null ? never : k]: Inp[k];
+};
+/**
+ * Converts or omits an object's keys according to a mapping.
+ *
+ * @param inp An object whose keys will be remapped
+ * @param mappings A mapping of original keys to new keys. If a key is not present in the mapping, it will be left as is. If a key is mapped to `null`, it will be removed in the resulting object.
+ * @returns A new object with keys remapped or omitted according to the mappings
+ */
+export declare function remap, const Mapping extends {
+ [k in keyof Inp]?: string | null;
+}>(inp: Inp, mappings: Mapping): Remap;
+//# sourceMappingURL=primitives.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/primitives.d.ts.map b/node_modules/@mistralai/mistralai/lib/primitives.d.ts.map
new file mode 100644
index 0000000000..f48c3085f8
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/primitives.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"primitives.d.ts","sourceRoot":"","sources":["../src/lib/primitives.ts"],"names":[],"mappings":"AAIA,MAAM,MAAM,KAAK,CAAC,GAAG,EAAE,OAAO,SAAS;KAAG,CAAC,IAAI,MAAM,GAAG,CAAC,CAAC,EAAE,MAAM,GAAG,IAAI;CAAE,IAAI;KAC5E,CAAC,IAAI,MAAM,GAAG,IAAI,OAAO,CAAC,CAAC,CAAC,SAAS,MAAM,GACxC,OAAO,CAAC,CAAC,CAAC,GACV,OAAO,CAAC,CAAC,CAAC,SAAS,IAAI,GACvB,KAAK,GACL,CAAC,GAAsC,GAAG,CAAC,CAAC,CAAC;CAClD,CAAC;AAEF;;;;;;GAMG;AACH,wBAAgB,KAAK,CACnB,GAAG,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACnC,KAAK,CAAC,OAAO,SAAS;KAAG,CAAC,IAAI,MAAM,GAAG,CAAC,CAAC,EAAE,MAAM,GAAG,IAAI;CAAE,EAC1D,GAAG,EAAE,GAAG,EAAE,QAAQ,EAAE,OAAO,GAAG,KAAK,CAAC,GAAG,EAAE,OAAO,CAAC,CAiBlD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/primitives.js b/node_modules/@mistralai/mistralai/lib/primitives.js
new file mode 100644
index 0000000000..b982c754d2
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/primitives.js
@@ -0,0 +1,29 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.remap = remap;
+/**
+ * Converts or omits an object's keys according to a mapping.
+ *
+ * @param inp An object whose keys will be remapped
+ * @param mappings A mapping of original keys to new keys. If a key is not present in the mapping, it will be left as is. If a key is mapped to `null`, it will be removed in the resulting object.
+ * @returns A new object with keys remapped or omitted according to the mappings
+ */
+function remap(inp, mappings) {
+ let out = {};
+ if (!Object.keys(mappings).length) {
+ out = inp;
+ return out;
+ }
+ for (const [k, v] of Object.entries(inp)) {
+ const j = mappings[k];
+ if (j === null) {
+ continue;
+ }
+ out[j !== null && j !== void 0 ? j : k] = v;
+ }
+ return out;
+}
+//# sourceMappingURL=primitives.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/primitives.js.map b/node_modules/@mistralai/mistralai/lib/primitives.js.map
new file mode 100644
index 0000000000..0f861538ac
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/primitives.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"primitives.js","sourceRoot":"","sources":["../src/lib/primitives.ts"],"names":[],"mappings":";AAAA;;GAEG;;AAiBH,sBAoBC;AA3BD;;;;;;GAMG;AACH,SAAgB,KAAK,CAGnB,GAAQ,EAAE,QAAiB;IAC3B,IAAI,GAAG,GAAQ,EAAE,CAAC;IAElB,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,MAAM,EAAE,CAAC;QAClC,GAAG,GAAG,GAAG,CAAC;QACV,OAAO,GAAG,CAAC;IACb,CAAC;IAED,KAAK,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;QACzC,MAAM,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,CAAC;QACtB,IAAI,CAAC,KAAK,IAAI,EAAE,CAAC;YACf,SAAS;QACX,CAAC;QACD,GAAG,CAAC,CAAC,aAAD,CAAC,cAAD,CAAC,GAAI,CAAC,CAAC,GAAG,CAAC,CAAC;IAClB,CAAC;IAED,OAAO,GAAG,CAAC;AACb,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/retries.d.ts b/node_modules/@mistralai/mistralai/lib/retries.d.ts
new file mode 100644
index 0000000000..fbd730bfb1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/retries.d.ts
@@ -0,0 +1,18 @@
+export type BackoffStrategy = {
+ initialInterval: number;
+ maxInterval: number;
+ exponent: number;
+ maxElapsedTime: number;
+};
+export type RetryConfig = {
+ strategy: "none";
+} | {
+ strategy: "backoff";
+ backoff?: BackoffStrategy;
+ retryConnectionErrors?: boolean;
+};
+export declare function retry(fetchFn: () => Promise, options: {
+ config: RetryConfig;
+ statusCodes: string[];
+}): Promise;
+//# sourceMappingURL=retries.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/retries.d.ts.map b/node_modules/@mistralai/mistralai/lib/retries.d.ts.map
new file mode 100644
index 0000000000..9ed6ab0688
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/retries.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"retries.d.ts","sourceRoot":"","sources":["../src/lib/retries.ts"],"names":[],"mappings":"AAMA,MAAM,MAAM,eAAe,GAAG;IAC5B,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,MAAM,CAAC;CACxB,CAAC;AASF,MAAM,MAAM,WAAW,GACnB;IAAE,QAAQ,EAAE,MAAM,CAAA;CAAE,GACpB;IACE,QAAQ,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,eAAe,CAAC;IAC1B,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC,CAAC;AAwBN,wBAAsB,KAAK,CACzB,OAAO,EAAE,MAAM,OAAO,CAAC,QAAQ,CAAC,EAChC,OAAO,EAAE;IACP,MAAM,EAAE,WAAW,CAAC;IACpB,WAAW,EAAE,MAAM,EAAE,CAAC;CACvB,GACA,OAAO,CAAC,QAAQ,CAAC,CAanB"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/retries.js b/node_modules/@mistralai/mistralai/lib/retries.js
new file mode 100644
index 0000000000..725c0c7155
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/retries.js
@@ -0,0 +1,130 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.retry = retry;
+const http_js_1 = require("./http.js");
+const defaultBackoff = {
+ initialInterval: 500,
+ maxInterval: 60000,
+ exponent: 1.5,
+ maxElapsedTime: 3600000,
+};
+class PermanentError extends Error {
+ constructor(inner) {
+ super("Permanent error");
+ this.inner = inner;
+ Object.setPrototypeOf(this, PermanentError.prototype);
+ }
+}
+class TemporaryError extends Error {
+ constructor(res) {
+ super("Temporary error");
+ this.res = res;
+ Object.setPrototypeOf(this, TemporaryError.prototype);
+ }
+}
+async function retry(fetchFn, options) {
+ var _a;
+ switch (options.config.strategy) {
+ case "backoff":
+ return retryBackoff(wrapFetcher(fetchFn, {
+ statusCodes: options.statusCodes,
+ retryConnectionErrors: !!options.config.retryConnectionErrors,
+ }), (_a = options.config.backoff) !== null && _a !== void 0 ? _a : defaultBackoff);
+ default:
+ return await fetchFn();
+ }
+}
+function wrapFetcher(fn, options) {
+ return async () => {
+ try {
+ const res = await fn();
+ if (isRetryableResponse(res, options.statusCodes)) {
+ throw new TemporaryError(res);
+ }
+ return res;
+ }
+ catch (err) {
+ if (err instanceof TemporaryError) {
+ throw err;
+ }
+ if (options.retryConnectionErrors &&
+ ((0, http_js_1.isTimeoutError)(err) || (0, http_js_1.isConnectionError)(err))) {
+ throw err;
+ }
+ throw new PermanentError(err);
+ }
+ };
+}
+const codeRangeRE = new RegExp("^[0-9]xx$", "i");
+function isRetryableResponse(res, statusCodes) {
+ const actual = `${res.status}`;
+ return statusCodes.some((code) => {
+ if (!codeRangeRE.test(code)) {
+ return code === actual;
+ }
+ const expectFamily = code.charAt(0);
+ if (!expectFamily) {
+ throw new Error("Invalid status code range");
+ }
+ const actualFamily = actual.charAt(0);
+ if (!actualFamily) {
+ throw new Error(`Invalid response status code: ${actual}`);
+ }
+ return actualFamily === expectFamily;
+ });
+}
+async function retryBackoff(fn, strategy) {
+ const { maxElapsedTime, initialInterval, exponent, maxInterval } = strategy;
+ const start = Date.now();
+ let x = 0;
+ // eslint-disable-next-line no-constant-condition
+ while (true) {
+ try {
+ const res = await fn();
+ return res;
+ }
+ catch (err) {
+ if (err instanceof PermanentError) {
+ throw err.inner;
+ }
+ const elapsed = Date.now() - start;
+ if (elapsed > maxElapsedTime) {
+ if (err instanceof TemporaryError) {
+ return err.res;
+ }
+ throw err;
+ }
+ let retryInterval = 0;
+ if (err instanceof TemporaryError && err.res && err.res.headers) {
+ const retryVal = err.res.headers.get("retry-after") || "";
+ if (retryVal != "") {
+ const parsedNumber = Number(retryVal);
+ if (!isNaN(parsedNumber) && Number.isInteger(parsedNumber)) {
+ retryInterval = parsedNumber * 1000;
+ }
+ else {
+ const parsedDate = Date.parse(retryVal);
+ if (!isNaN(parsedDate)) {
+ const deltaMS = parsedDate - Date.now();
+ retryInterval = deltaMS > 0 ? Math.ceil(deltaMS) : 0;
+ }
+ }
+ }
+ }
+ if (retryInterval == 0) {
+ retryInterval =
+ initialInterval * Math.pow(x, exponent) + Math.random() * 1000;
+ }
+ const d = Math.min(retryInterval, maxInterval);
+ await delay(d);
+ x++;
+ }
+ }
+}
+async function delay(delay) {
+ return new Promise((resolve) => setTimeout(resolve, delay));
+}
+//# sourceMappingURL=retries.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/retries.js.map b/node_modules/@mistralai/mistralai/lib/retries.js.map
new file mode 100644
index 0000000000..34b3dcdd6c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/retries.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"retries.js","sourceRoot":"","sources":["../src/lib/retries.ts"],"names":[],"mappings":";AAAA;;GAEG;;AAgDH,sBAmBC;AAjED,uCAA8D;AAS9D,MAAM,cAAc,GAAoB;IACtC,eAAe,EAAE,GAAG;IACpB,WAAW,EAAE,KAAK;IAClB,QAAQ,EAAE,GAAG;IACb,cAAc,EAAE,OAAO;CACxB,CAAC;AAUF,MAAM,cAAe,SAAQ,KAAK;IAGhC,YAAY,KAAc;QACxB,KAAK,CAAC,iBAAiB,CAAC,CAAC;QACzB,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QAEnB,MAAM,CAAC,cAAc,CAAC,IAAI,EAAE,cAAc,CAAC,SAAS,CAAC,CAAC;IACxD,CAAC;CACF;AAED,MAAM,cAAe,SAAQ,KAAK;IAGhC,YAAY,GAAa;QACvB,KAAK,CAAC,iBAAiB,CAAC,CAAC;QAC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,EAAE,QAAQ,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,CAAC;YACnE,CAAC;YAED,MAAM,CAAC,GAAG,IAAI,CAAC,GAAG,CAAC,aAAa,EAAE,WAAW,CAAC,CAAC;YAE/C,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC;YACf,CAAC,EAAE,CAAC;QACN,CAAC;IACH,CAAC;AACH,CAAC;AAED,KAAK,UAAU,KAAK,CAAC,KAAa;IAChC,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC;AAC9D,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/schemas.d.ts b/node_modules/@mistralai/mistralai/lib/schemas.d.ts
new file mode 100644
index 0000000000..558fff993d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/schemas.d.ts
@@ -0,0 +1,19 @@
+import { output, ZodEffects, ZodObject, ZodRawShape, ZodTypeAny } from "zod";
+import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
+import { Result } from "../types/fp.js";
+/**
+ * Utility function that executes some code which may throw a ZodError. It
+ * intercepts this error and converts it to an SDKValidationError so as to not
+ * leak Zod implementation details to user code.
+ */
+export declare function parse(rawValue: Inp, fn: (value: Inp) => Out, errorMessage: string): Out;
+/**
+ * Utility function that executes some code which may result in a ZodError. It
+ * intercepts this error and converts it to an SDKValidationError so as to not
+ * leak Zod implementation details to user code.
+ */
+export declare function safeParse(rawValue: Inp, fn: (value: Inp) => Out, errorMessage: string): Result;
+export declare function collectExtraKeys(obj: ZodObject, extrasKey: K): ZodEffects> & {
+ [k in K]: Record>;
+}>;
+//# sourceMappingURL=schemas.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/schemas.d.ts.map b/node_modules/@mistralai/mistralai/lib/schemas.d.ts.map
new file mode 100644
index 0000000000..5314b06686
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/schemas.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../src/lib/schemas.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,MAAM,EACN,UAAU,EAEV,SAAS,EACT,WAAW,EACX,UAAU,EACX,MAAM,KAAK,CAAC;AACb,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,EAAW,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAEjD;;;;GAIG;AACH,wBAAgB,KAAK,CAAC,GAAG,EAAE,GAAG,EAC5B,QAAQ,EAAE,GAAG,EACb,EAAE,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,GAAG,EACvB,YAAY,EAAE,MAAM,GACnB,GAAG,CASL;AAED;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,GAAG,EAAE,GAAG,EAChC,QAAQ,EAAE,GAAG,EACb,EAAE,EAAE,CAAC,KAAK,EAAE,GAAG,KAAK,GAAG,EACvB,YAAY,EAAE,MAAM,GACnB,MAAM,CAAC,GAAG,EAAE,kBAAkB,CAAC,CAMjC;AAED,wBAAgB,gBAAgB,CAC9B,KAAK,SAAS,WAAW,EACzB,QAAQ,SAAS,UAAU,EAC3B,CAAC,SAAS,MAAM,EAEhB,GAAG,EAAE,SAAS,CAAC,KAAK,EAAE,OAAO,EAAE,QAAQ,CAAC,EACxC,SAAS,EAAE,CAAC,GACX,UAAU,CACX,OAAO,GAAG,EACR,MAAM,CAAC,SAAS,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC,GAClC;KACC,CAAC,IAAI,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,QAAQ,CAAC,CAAC;CAC3C,CACF,CAoBA"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/schemas.js b/node_modules/@mistralai/mistralai/lib/schemas.js
new file mode 100644
index 0000000000..c16c8f9633
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/schemas.js
@@ -0,0 +1,59 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.parse = parse;
+exports.safeParse = safeParse;
+exports.collectExtraKeys = collectExtraKeys;
+const zod_1 = require("zod");
+const sdkvalidationerror_js_1 = require("../models/errors/sdkvalidationerror.js");
+const fp_js_1 = require("../types/fp.js");
+/**
+ * Utility function that executes some code which may throw a ZodError. It
+ * intercepts this error and converts it to an SDKValidationError so as to not
+ * leak Zod implementation details to user code.
+ */
+function parse(rawValue, fn, errorMessage) {
+ try {
+ return fn(rawValue);
+ }
+ catch (err) {
+ if (err instanceof zod_1.ZodError) {
+ throw new sdkvalidationerror_js_1.SDKValidationError(errorMessage, err, rawValue);
+ }
+ throw err;
+ }
+}
+/**
+ * Utility function that executes some code which may result in a ZodError. It
+ * intercepts this error and converts it to an SDKValidationError so as to not
+ * leak Zod implementation details to user code.
+ */
+function safeParse(rawValue, fn, errorMessage) {
+ try {
+ return (0, fp_js_1.OK)(fn(rawValue));
+ }
+ catch (err) {
+ return (0, fp_js_1.ERR)(new sdkvalidationerror_js_1.SDKValidationError(errorMessage, err, rawValue));
+ }
+}
+function collectExtraKeys(obj, extrasKey) {
+ return obj.transform((val) => {
+ const extras = {};
+ const { shape } = obj;
+ for (const [key] of Object.entries(val)) {
+ if (key in shape) {
+ continue;
+ }
+ const v = val[key];
+ if (typeof v === "undefined") {
+ continue;
+ }
+ extras[key] = v;
+ delete val[key];
+ }
+ return { ...val, [extrasKey]: extras };
+ });
+}
+//# sourceMappingURL=schemas.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/schemas.js.map b/node_modules/@mistralai/mistralai/lib/schemas.js.map
new file mode 100644
index 0000000000..6d803748c9
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/schemas.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"schemas.js","sourceRoot":"","sources":["../src/l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WAAW,EAAE,CAAC;gBAC7B,SAAS;YACX,CAAC;YAED,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;YAChB,OAAO,GAAG,CAAC,GAAG,CAAC,CAAC;QAClB,CAAC;QAED,OAAO,EAAE,GAAG,GAAG,EAAE,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACzC,CAAC,CAAC,CAAC;AACL,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/sdks.d.ts b/node_modules/@mistralai/mistralai/lib/sdks.d.ts
new file mode 100644
index 0000000000..8ab8a230ca
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/sdks.d.ts
@@ -0,0 +1,59 @@
+import { SDKHooks } from "../hooks/hooks.js";
+import { HookContext } from "../hooks/types.js";
+import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
+import { Result } from "../types/fp.js";
+import { SDKOptions } from "./config.js";
+import { Logger } from "./logger.js";
+import { RetryConfig } from "./retries.js";
+import { SecurityState } from "./security.js";
+export type RequestOptions = {
+ /**
+ * Sets a timeout, in milliseconds, on HTTP requests made by an SDK method. If
+ * `fetchOptions.signal` is set then it will take precedence over this option.
+ */
+ timeoutMs?: number;
+ /**
+ * Set or override a retry policy on HTTP calls.
+ */
+ retries?: RetryConfig;
+ /**
+ * Specifies the status codes which should be retried using the given retry policy.
+ */
+ retryCodes?: string[];
+ /**
+ * Sets various request options on the `fetch` call made by an SDK method.
+ *
+ * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options|Request}
+ */
+ fetchOptions?: Omit;
+};
+type RequestConfig = {
+ method: string;
+ path: string;
+ baseURL?: string | URL;
+ query?: string;
+ body?: RequestInit["body"];
+ headers?: HeadersInit;
+ security?: SecurityState | null;
+ uaHeader?: string;
+ timeoutMs?: number;
+};
+export declare class ClientSDK {
+ private readonly httpClient;
+ protected readonly baseURL: URL | null;
+ protected readonly hooks$: SDKHooks;
+ protected readonly logger?: Logger | undefined;
+ readonly options$: SDKOptions & {
+ hooks?: SDKHooks;
+ };
+ constructor(options?: SDKOptions);
+ createRequest$(context: HookContext, conf: RequestConfig, options?: RequestOptions): Result;
+ do$(request: Request, options: {
+ context: HookContext;
+ errorCodes: number | string | (number | string)[];
+ retryConfig?: RetryConfig | undefined;
+ retryCodes?: string[] | undefined;
+ }): Promise>;
+}
+export {};
+//# sourceMappingURL=sdks.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/sdks.d.ts.map b/node_modules/@mistralai/mistralai/lib/sdks.d.ts.map
new file mode 100644
index 0000000000..af5d2ef11e
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/sdks.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"sdks.d.ts","sourceRoot":"","sources":["../src/lib/sdks.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAW,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAEjD,OAAO,EAAgB,UAAU,EAAwB,MAAM,aAAa,CAAC;AAW7E,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAS,WAAW,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAE9C,MAAM,MAAM,cAAc,GAAG;IAC3B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB;;;;OAIG;IACH,YAAY,CAA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E,MAAM,EAAE,GAAG,SAAS,CAAC;KACnC,GACA,OAAO,CACR,MAAM,CACJ,QAAQ,EACN,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,GACf,qBAAqB,CACxB,CACF;CA0DF"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/sdks.js b/node_modules/@mistralai/mistralai/lib/sdks.js
new file mode 100644
index 0000000000..fd58418a90
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/sdks.js
@@ -0,0 +1,259 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.ClientSDK = void 0;
+const hooks_js_1 = require("../hooks/hooks.js");
+const httpclienterrors_js_1 = require("../models/errors/httpclienterrors.js");
+const fp_js_1 = require("../types/fp.js");
+const base64_js_1 = require("./base64.js");
+const config_js_1 = require("./config.js");
+const encodings_js_1 = require("./encodings.js");
+const env_js_1 = require("./env.js");
+const http_js_1 = require("./http.js");
+const retries_js_1 = require("./retries.js");
+const gt = typeof globalThis === "undefined" ? null : globalThis;
+const webWorkerLike = typeof gt === "object"
+ && gt != null
+ && "importScripts" in gt
+ && typeof gt["importScripts"] === "function";
+const isBrowserLike = webWorkerLike
+ || (typeof navigator !== "undefined" && "serviceWorker" in navigator)
+ || (typeof window === "object" && typeof window.document !== "undefined");
+class ClientSDK {
+ constructor(options = {}) {
+ const opt = options;
+ if (typeof opt === "object"
+ && opt != null
+ && "hooks" in opt
+ && opt.hooks instanceof hooks_js_1.SDKHooks) {
+ this.hooks$ = opt.hooks;
+ }
+ else {
+ this.hooks$ = new hooks_js_1.SDKHooks();
+ }
+ this.options$ = { ...options, hooks: this.hooks$ };
+ const url = (0, config_js_1.serverURLFromOptions)(options);
+ if (url) {
+ url.pathname = url.pathname.replace(/\/+$/, "") + "/";
+ }
+ const { baseURL, client } = this.hooks$.sdkInit({
+ baseURL: url,
+ client: options.httpClient || new http_js_1.HTTPClient(),
+ });
+ this.baseURL = baseURL;
+ this.httpClient = client;
+ this.logger = options.debugLogger;
+ if (!this.logger && (0, env_js_1.env)().MISTRAL_DEBUG) {
+ this.logger = console;
+ }
+ }
+ createRequest$(context, conf, options) {
+ var _a, _b, _c, _d;
+ const { method, path, query, headers: opHeaders, security } = conf;
+ const base = (_a = conf.baseURL) !== null && _a !== void 0 ? _a : this.baseURL;
+ if (!base) {
+ return (0, fp_js_1.ERR)(new httpclienterrors_js_1.InvalidRequestError("No base URL provided for operation"));
+ }
+ const reqURL = new URL(base);
+ const inputURL = new URL(path, reqURL);
+ if (path) {
+ reqURL.pathname += inputURL.pathname.replace(/^\/+/, "");
+ }
+ let finalQuery = query || "";
+ const secQuery = [];
+ for (const [k, v] of Object.entries((security === null || security === void 0 ? void 0 : security.queryParams) || {})) {
+ secQuery.push((0, encodings_js_1.encodeForm)(k, v, { charEncoding: "percent" }));
+ }
+ if (secQuery.length) {
+ finalQuery += `&${secQuery.join("&")}`;
+ }
+ if (finalQuery) {
+ const q = finalQuery.startsWith("&") ? finalQuery.slice(1) : finalQuery;
+ reqURL.search = `?${q}`;
+ }
+ const headers = new Headers(opHeaders);
+ const username = security === null || security === void 0 ? void 0 : security.basic.username;
+ const password = security === null || security === void 0 ? void 0 : security.basic.password;
+ if (username != null || password != null) {
+ const encoded = (0, base64_js_1.stringToBase64)([username || "", password || ""].join(":"));
+ headers.set("Authorization", `Basic ${encoded}`);
+ }
+ const securityHeaders = new Headers((security === null || security === void 0 ? void 0 : security.headers) || {});
+ for (const [k, v] of securityHeaders) {
+ headers.set(k, v);
+ }
+ let cookie = headers.get("cookie") || "";
+ for (const [k, v] of Object.entries((security === null || security === void 0 ? void 0 : security.cookies) || {})) {
+ cookie += `; ${k}=${v}`;
+ }
+ cookie = cookie.startsWith("; ") ? cookie.slice(2) : cookie;
+ headers.set("cookie", cookie);
+ const userHeaders = new Headers((_b = options === null || options === void 0 ? void 0 : options.fetchOptions) === null || _b === void 0 ? void 0 : _b.headers);
+ for (const [k, v] of userHeaders) {
+ headers.set(k, v);
+ }
+ // Only set user agent header in non-browser-like environments since CORS
+ // policy disallows setting it in browsers e.g. Chrome throws an error.
+ if (!isBrowserLike) {
+ headers.set((_c = conf.uaHeader) !== null && _c !== void 0 ? _c : "user-agent", config_js_1.SDK_METADATA.userAgent);
+ }
+ let fetchOptions = options === null || options === void 0 ? void 0 : options.fetchOptions;
+ if (!(fetchOptions === null || fetchOptions === void 0 ? void 0 : fetchOptions.signal) && conf.timeoutMs && conf.timeoutMs > 0) {
+ const timeoutSignal = AbortSignal.timeout(conf.timeoutMs);
+ if (!fetchOptions) {
+ fetchOptions = { signal: timeoutSignal };
+ }
+ else {
+ fetchOptions.signal = timeoutSignal;
+ }
+ }
+ if (conf.body instanceof ReadableStream) {
+ if (!fetchOptions) {
+ fetchOptions = {
+ // @ts-expect-error see https://github.com/node-fetch/node-fetch/issues/1769
+ duplex: "half",
+ };
+ }
+ else {
+ // @ts-expect-error see https://github.com/node-fetch/node-fetch/issues/1769
+ fetchOptions.duplex = "half";
+ }
+ }
+ let input;
+ try {
+ input = this.hooks$.beforeCreateRequest(context, {
+ url: reqURL,
+ options: {
+ ...fetchOptions,
+ body: (_d = conf.body) !== null && _d !== void 0 ? _d : null,
+ headers,
+ method,
+ },
+ });
+ }
+ catch (err) {
+ return (0, fp_js_1.ERR)(new httpclienterrors_js_1.UnexpectedClientError("Create request hook failed to execute", {
+ cause: err,
+ }));
+ }
+ return (0, fp_js_1.OK)(new Request(input.url, input.options));
+ }
+ async do$(request, options) {
+ const { context, errorCodes } = options;
+ const retryConfig = options.retryConfig || { strategy: "none" };
+ const retryCodes = options.retryCodes || [];
+ return (0, retries_js_1.retry)(async () => {
+ const req = await this.hooks$.beforeRequest(context, request.clone());
+ await logRequest(this.logger, req).catch((e) => { var _a; return (_a = this.logger) === null || _a === void 0 ? void 0 : _a.log("Failed to log request:", e); });
+ let response = await this.httpClient.request(req);
+ if ((0, http_js_1.matchStatusCode)(response, errorCodes)) {
+ const result = await this.hooks$.afterError(context, response, null);
+ if (result.error) {
+ throw result.error;
+ }
+ response = result.response || response;
+ }
+ else {
+ response = await this.hooks$.afterSuccess(context, response);
+ }
+ await logResponse(this.logger, response, req)
+ .catch(e => { var _a; return (_a = this.logger) === null || _a === void 0 ? void 0 : _a.log("Failed to log response:", e); });
+ return response;
+ }, { config: retryConfig, statusCodes: retryCodes }).then((r) => (0, fp_js_1.OK)(r), (err) => {
+ switch (true) {
+ case (0, http_js_1.isAbortError)(err):
+ return (0, fp_js_1.ERR)(new httpclienterrors_js_1.RequestAbortedError("Request aborted by client", {
+ cause: err,
+ }));
+ case (0, http_js_1.isTimeoutError)(err):
+ return (0, fp_js_1.ERR)(new httpclienterrors_js_1.RequestTimeoutError("Request timed out", { cause: err }));
+ case (0, http_js_1.isConnectionError)(err):
+ return (0, fp_js_1.ERR)(new httpclienterrors_js_1.ConnectionError("Unable to make request", { cause: err }));
+ default:
+ return (0, fp_js_1.ERR)(new httpclienterrors_js_1.UnexpectedClientError("Unexpected HTTP client error", {
+ cause: err,
+ }));
+ }
+ });
+ }
+}
+exports.ClientSDK = ClientSDK;
+const jsonLikeContentTypeRE = /^application\/(?:.{0,100}\+)?json/;
+async function logRequest(logger, req) {
+ if (!logger) {
+ return;
+ }
+ const contentType = req.headers.get("content-type");
+ const ct = (contentType === null || contentType === void 0 ? void 0 : contentType.split(";")[0]) || "";
+ logger.group(`> Request: ${req.method} ${req.url}`);
+ logger.group("Headers:");
+ for (const [k, v] of req.headers.entries()) {
+ logger.log(`${k}: ${v}`);
+ }
+ logger.groupEnd();
+ logger.group("Body:");
+ switch (true) {
+ case jsonLikeContentTypeRE.test(ct):
+ logger.log(await req.clone().json());
+ break;
+ case ct.startsWith("text/"):
+ logger.log(await req.clone().text());
+ break;
+ case ct === "multipart/form-data": {
+ const body = await req.clone().formData();
+ for (const [k, v] of body) {
+ const vlabel = v instanceof Blob ? "" : v;
+ logger.log(`${k}: ${vlabel}`);
+ }
+ break;
+ }
+ default:
+ logger.log(`<${contentType}>`);
+ break;
+ }
+ logger.groupEnd();
+ logger.groupEnd();
+}
+async function logResponse(logger, res, req) {
+ if (!logger) {
+ return;
+ }
+ const contentType = res.headers.get("content-type");
+ const ct = (contentType === null || contentType === void 0 ? void 0 : contentType.split(";")[0]) || "";
+ logger.group(`< Response: ${req.method} ${req.url}`);
+ logger.log("Status Code:", res.status, res.statusText);
+ logger.group("Headers:");
+ for (const [k, v] of res.headers.entries()) {
+ logger.log(`${k}: ${v}`);
+ }
+ logger.groupEnd();
+ logger.group("Body:");
+ switch (true) {
+ case (0, http_js_1.matchContentType)(res, "application/json")
+ || jsonLikeContentTypeRE.test(ct):
+ logger.log(await res.clone().json());
+ break;
+ case (0, http_js_1.matchContentType)(res, "text/event-stream"):
+ logger.log(`<${contentType}>`);
+ break;
+ case (0, http_js_1.matchContentType)(res, "text/*"):
+ logger.log(await res.clone().text());
+ break;
+ case (0, http_js_1.matchContentType)(res, "multipart/form-data"): {
+ const body = await res.clone().formData();
+ for (const [k, v] of body) {
+ const vlabel = v instanceof Blob ? "" : v;
+ logger.log(`${k}: ${vlabel}`);
+ }
+ break;
+ }
+ default:
+ logger.log(`<${contentType}>`);
+ break;
+ }
+ logger.groupEnd();
+ logger.groupEnd();
+}
+//# sourceMappingURL=sdks.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/sdks.js.map b/node_modules/@mistralai/mistralai/lib/sdks.js.map
new file mode 100644
index 0000000000..ff3b2ef9fe
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/sdks.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"sdks.js","sourceRoot":"","sources":["../src/lib/sdks.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,gDAA6C;AAE7C,8EAM8C;AAC9C,0CAAiD;AACjD,2CAA6C;AAC7C,2CAA6E;AAC7E,iDAA4C;AAC5C,qCAA+B;AAC/B,uCAOmB;AAEnB,6CAAkD;AAqCl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rC,MAAM;QACR,KAAK,IAAA,0BAAgB,EAAC,GAAG,EAAE,mBAAmB,CAAC;YAC7C,MAAM,CAAC,GAAG,CAAC,IAAI,WAAW,GAAG,CAAC,CAAC;YAC/B,MAAM;QACR,KAAK,IAAA,0BAAgB,EAAC,GAAG,EAAE,QAAQ,CAAC;YAClC,MAAM,CAAC,GAAG,CAAC,MAAM,GAAG,CAAC,KAAK,EAAE,CAAC,IAAI,EAAE,CAAC,CAAC;YACrC,MAAM;QACR,KAAK,IAAA,0BAAgB,EAAC,GAAG,EAAE,qBAAqB,CAAC,CAAC,CAAC,CAAC;YAClD,MAAM,IAAI,GAAG,MAAM,GAAG,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE,CAAC;YAC1C,KAAK,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,IAAI,EAAE,CAAC;gBAC1B,MAAM,MAAM,GAAG,CAAC,YAAY,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC;gBAChD,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,KAAK,MAAM,EAAE,CAAC,CAAC;YAChC,CAAC;YACD,MAAM;QACR,CAAC;QACD;YACE,MAAM,CAAC,GAAG,CAAC,IAAI,WAAW,GAAG,CAAC,CAAC;YAC/B,MAAM;IACV,CAAC;IACD,MAAM,CAAC,QAAQ,EAAE,CAAC;IAElB,MAAM,CAAC,QAAQ,EAAE,CAAC;AACpB,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/security.d.ts b/node_modules/@mistralai/mistralai/lib/security.d.ts
new file mode 100644
index 0000000000..699970021f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/security.d.ts
@@ -0,0 +1,63 @@
+import * as components from "../models/components/index.js";
+export declare enum SecurityErrorCode {
+ Incomplete = "incomplete",
+ UnrecognisedSecurityType = "unrecognized_security_type"
+}
+export declare class SecurityError extends Error {
+ code: SecurityErrorCode;
+ constructor(code: SecurityErrorCode, message: string);
+ static incomplete(): SecurityError;
+ static unrecognizedType(type: string): SecurityError;
+}
+export type SecurityState = {
+ basic: {
+ username?: string | undefined;
+ password?: string | undefined;
+ };
+ headers: Record;
+ queryParams: Record;
+ cookies: Record;
+};
+type SecurityInputBasic = {
+ type: "http:basic";
+ value: {
+ username?: string | undefined;
+ password?: string | undefined;
+ } | null | undefined;
+};
+type SecurityInputBearer = {
+ type: "http:bearer";
+ value: string | null | undefined;
+ fieldName: string;
+};
+type SecurityInputAPIKey = {
+ type: "apiKey:header" | "apiKey:query" | "apiKey:cookie";
+ value: string | null | undefined;
+ fieldName: string;
+};
+type SecurityInputOIDC = {
+ type: "openIdConnect";
+ value: string | null | undefined;
+ fieldName: string;
+};
+type SecurityInputOAuth2 = {
+ type: "oauth2";
+ value: string | null | undefined;
+ fieldName: string;
+};
+type SecurityInputOAuth2ClientCredentials = {
+ type: "oauth2:client_credentials";
+ value: string | null | undefined;
+ fieldName: string;
+};
+type SecurityInputCustom = {
+ type: "http:custom";
+ value: any | null | undefined;
+ fieldName: string;
+};
+export type SecurityInput = SecurityInputBasic | SecurityInputBearer | SecurityInputAPIKey | SecurityInputOAuth2 | SecurityInputOAuth2ClientCredentials | SecurityInputOIDC | SecurityInputCustom;
+export declare function resolveSecurity(...options: SecurityInput[][]): SecurityState | null;
+export declare function resolveGlobalSecurity(security: Partial | null | undefined): SecurityState | null;
+export declare function extractSecurity>(sec: T | (() => Promise) | undefined): Promise;
+export {};
+//# sourceMappingURL=security.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/security.d.ts.map b/node_modules/@mistralai/mistralai/lib/security.d.ts.map
new file mode 100644
index 0000000000..46829eab74
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/security.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"security.d.ts","sourceRoot":"","sources":["../src/lib/security.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AA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security.js
new file mode 100644
index 0000000000..a1f9ae6194
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/security.js
@@ -0,0 +1,130 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.SecurityError = exports.SecurityErrorCode = void 0;
+exports.resolveSecurity = resolveSecurity;
+exports.resolveGlobalSecurity = resolveGlobalSecurity;
+exports.extractSecurity = extractSecurity;
+const env_js_1 = require("./env.js");
+var SecurityErrorCode;
+(function (SecurityErrorCode) {
+ SecurityErrorCode["Incomplete"] = "incomplete";
+ SecurityErrorCode["UnrecognisedSecurityType"] = "unrecognized_security_type";
+})(SecurityErrorCode || (exports.SecurityErrorCode = SecurityErrorCode = {}));
+class SecurityError extends Error {
+ constructor(code, message) {
+ super(message);
+ this.code = code;
+ this.name = "SecurityError";
+ }
+ static incomplete() {
+ return new SecurityError(SecurityErrorCode.Incomplete, "Security requirements not met in order to perform the operation");
+ }
+ static unrecognizedType(type) {
+ return new SecurityError(SecurityErrorCode.UnrecognisedSecurityType, `Unrecognised security type: ${type}`);
+ }
+}
+exports.SecurityError = SecurityError;
+function resolveSecurity(...options) {
+ const state = {
+ basic: { username: "", password: "" },
+ headers: {},
+ queryParams: {},
+ cookies: {},
+ };
+ const option = options.find((opts) => {
+ return opts.every((o) => {
+ if (o.value == null) {
+ return false;
+ }
+ else if (o.type === "http:basic") {
+ return o.value.username != null || o.value.password != null;
+ }
+ else if (o.type === "http:custom") {
+ return null;
+ }
+ else if (typeof o.value === "string") {
+ return !!o.value;
+ }
+ else {
+ throw new Error(`Unrecognized security type: ${o.type} (value type: ${typeof o
+ .value})`);
+ }
+ });
+ });
+ if (option == null) {
+ return null;
+ }
+ option.forEach((spec) => {
+ if (spec.value == null) {
+ return;
+ }
+ const { type } = spec;
+ switch (type) {
+ case "apiKey:header":
+ state.headers[spec.fieldName] = spec.value;
+ break;
+ case "apiKey:query":
+ state.queryParams[spec.fieldName] = spec.value;
+ break;
+ case "apiKey:cookie":
+ state.cookies[spec.fieldName] = spec.value;
+ break;
+ case "http:basic":
+ applyBasic(state, spec);
+ break;
+ case "http:custom":
+ break;
+ case "http:bearer":
+ applyBearer(state, spec);
+ break;
+ case "oauth2":
+ applyBearer(state, spec);
+ break;
+ case "oauth2:client_credentials":
+ break;
+ case "openIdConnect":
+ applyBearer(state, spec);
+ break;
+ default:
+ spec;
+ throw SecurityError.unrecognizedType(type);
+ }
+ });
+ return state;
+}
+function applyBasic(state, spec) {
+ if (spec.value == null) {
+ return;
+ }
+ state.basic = spec.value;
+}
+function applyBearer(state, spec) {
+ if (spec.value == null) {
+ return;
+ }
+ let value = spec.value;
+ if (value.slice(0, 7).toLowerCase() !== "bearer ") {
+ value = `Bearer ${value}`;
+ }
+ state.headers[spec.fieldName] = value;
+}
+function resolveGlobalSecurity(security) {
+ var _a;
+ return resolveSecurity([
+ {
+ fieldName: "Authorization",
+ type: "http:bearer",
+ value: (_a = security === null || security === void 0 ? void 0 : security.apiKey) !== null && _a !== void 0 ? _a : (0, env_js_1.env)().MISTRAL_API_KEY,
+ },
+ ]);
+}
+async function extractSecurity(sec) {
+ if (sec == null) {
+ return;
+ }
+ return typeof sec === "function" ? sec() : sec;
+}
+//# sourceMappingURL=security.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/security.js.map b/node_modules/@mistralai/mistralai/lib/security.js.map
new file mode 100644
index 0000000000..126cefaadf
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/security.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"security.js","sourceRoot":"","sources":["../src/lib/security.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AA6FH,0CAwEC;AA4BD,sDAYC;AAED,0CAQC;AApND,qCAA+B;AAE/B,IAAY,iBAGX;AAHD,WAAY,iBAAiB;IAC3B,8CAAyB,CAAA;IACzB,4EAAuD,CAAA;AACzD,CAAC,EAHW,iBAAiB,iCAAjB,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,CAAC,GAAG,CAAC;AACjD,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/url.d.ts b/node_modules/@mistralai/mistralai/lib/url.d.ts
new file mode 100644
index 0000000000..68df948004
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/url.d.ts
@@ -0,0 +1,5 @@
+export type Params = Partial>;
+export declare function pathToFunc(pathPattern: string, options?: {
+ charEncoding?: "percent" | "none";
+}): (params?: Params) => string;
+//# sourceMappingURL=url.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/url.d.ts.map b/node_modules/@mistralai/mistralai/lib/url.d.ts.map
new file mode 100644
index 0000000000..0670c05e17
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/url.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"url.d.ts","sourceRoot":"","sources":["../src/lib/url.ts"],"names":[],"mappings":"AAMA,MAAM,MAAM,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC,CAAC;AAE9D,wBAAgB,UAAU,CACxB,WAAW,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE;IAAE,YAAY,CAAC,EAAE,SAAS,GAAG,MAAM,CAAA;CAAE,GAC9C,CAAC,MAAM,CAAC,EAAE,MAAM,KAAK,MAAM,CAqB7B"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/url.js b/node_modules/@mistralai/mistralai/lib/url.js
new file mode 100644
index 0000000000..bfc4ff3028
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/url.js
@@ -0,0 +1,25 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.pathToFunc = pathToFunc;
+const hasOwn = Object.prototype.hasOwnProperty;
+function pathToFunc(pathPattern, options) {
+ const paramRE = /\{([a-zA-Z0-9_]+?)\}/g;
+ return function buildURLPath(params = {}) {
+ return pathPattern.replace(paramRE, function (_, placeholder) {
+ if (!hasOwn.call(params, placeholder)) {
+ throw new Error(`Parameter '${placeholder}' is required`);
+ }
+ const value = params[placeholder];
+ if (typeof value !== "string" && typeof value !== "number") {
+ throw new Error(`Parameter '${placeholder}' must be a string or number`);
+ }
+ return (options === null || options === void 0 ? void 0 : options.charEncoding) === "percent"
+ ? encodeURIComponent(`${value}`)
+ : `${value}`;
+ });
+ };
+}
+//# sourceMappingURL=url.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/lib/url.js.map b/node_modules/@mistralai/mistralai/lib/url.js.map
new file mode 100644
index 0000000000..b85932b659
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/lib/url.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"url.js","sourceRoot":"","sources":["../src/lib/url.ts"],"names":[],"mappings":";AAAA;;GAEG;;AAMH,gCAwBC;AA5BD,MAAM,MAAM,GAAG,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC;AAI/C,SAAgB,UAAU,CACxB,WAAmB,EACnB,OAA+C;IAE/C,MAAM,OAAO,GAAG,uBAAuB,CAAC;IAExC,OAAO,SAAS,YAAY,CAAC,SAAkC,EAAE;QAC/D,OAAO,WAAW,CAAC,OAAO,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,WAAW;YAC1D,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,EAAE,WAAW,CAAC,EAAE,CAAC;gBACtC,MAAM,IAAI,KAAK,CAAC,cAAc,WAAW,eAAe,CAAC,CAAC;YAC5D,CAAC;YAED,MAAM,KAAK,GAAG,MAAM,CAAC,WAAW,CAAC,CAAC;YAClC,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;gBAC3D,MAAM,IAAI,KAAK,CACb,cAAc,WAAW,8BAA8B,CACxD,CAAC;YACJ,CAAC;YAED,OAAO,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAE,YAAY,MAAK,SAAS;gBACxC,CAAC,CAAC,kBAAkB,CAAC,GAAG,KAAK,EAAE,CAAC;gBAChC,CAAC,CAAC,GAAG,KAAK,EAAE,CAAC;QACjB,CAAC,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.d.ts b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.d.ts
new file mode 100644
index 0000000000..2ff5bf6db5
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.d.ts
@@ -0,0 +1,155 @@
+import * as z from "zod";
+import { AssistantMessage, AssistantMessage$Outbound } from "./assistantmessage.js";
+import { ResponseFormat, ResponseFormat$Outbound } from "./responseformat.js";
+import { Tool, Tool$Outbound } from "./tool.js";
+import { ToolChoice, ToolChoice$Outbound } from "./toolchoice.js";
+import { ToolChoiceEnum } from "./toolchoiceenum.js";
+import { ToolMessage, ToolMessage$Outbound } from "./toolmessage.js";
+import { UserMessage, UserMessage$Outbound } from "./usermessage.js";
+/**
+ * Stop generation if this token is detected. Or if one of these tokens is detected when providing an array
+ */
+export type AgentsCompletionRequestStop = string | Array;
+export type AgentsCompletionRequestMessages = (UserMessage & {
+ role: "user";
+}) | (AssistantMessage & {
+ role: "assistant";
+}) | (ToolMessage & {
+ role: "tool";
+});
+export type AgentsCompletionRequestToolChoice = ToolChoice | ToolChoiceEnum;
+export type AgentsCompletionRequest = {
+ /**
+ * The maximum number of tokens to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model's context length.
+ */
+ maxTokens?: number | null | undefined;
+ /**
+ * The minimum number of tokens to generate in the completion.
+ */
+ minTokens?: number | null | undefined;
+ /**
+ * Whether to stream back partial progress. If set, tokens will be sent as data-only server-side events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+ stream?: boolean | undefined;
+ /**
+ * Stop generation if this token is detected. Or if one of these tokens is detected when providing an array
+ */
+ stop?: string | Array | undefined;
+ /**
+ * The seed to use for random sampling. If set, different calls will generate deterministic results.
+ */
+ randomSeed?: number | null | undefined;
+ /**
+ * The prompt(s) to generate completions for, encoded as a list of dict with role and content.
+ */
+ messages: Array<(UserMessage & {
+ role: "user";
+ }) | (AssistantMessage & {
+ role: "assistant";
+ }) | (ToolMessage & {
+ role: "tool";
+ })>;
+ responseFormat?: ResponseFormat | undefined;
+ tools?: Array | null | undefined;
+ toolChoice?: ToolChoice | ToolChoiceEnum | undefined;
+ /**
+ * The ID of the agent to use for this completion.
+ */
+ agentId: string;
+};
+/** @internal */
+export declare const AgentsCompletionRequestStop$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionRequestStop$Outbound = string | Array;
+/** @internal */
+export declare const AgentsCompletionRequestStop$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionRequestStop$ {
+ /** @deprecated use `AgentsCompletionRequestStop$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequestStop$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequestStop$Outbound` instead. */
+ type Outbound = AgentsCompletionRequestStop$Outbound;
+}
+/** @internal */
+export declare const AgentsCompletionRequestMessages$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionRequestMessages$Outbound = (UserMessage$Outbound & {
+ role: "user";
+}) | (AssistantMessage$Outbound & {
+ role: "assistant";
+}) | (ToolMessage$Outbound & {
+ role: "tool";
+});
+/** @internal */
+export declare const AgentsCompletionRequestMessages$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionRequestMessages$ {
+ /** @deprecated use `AgentsCompletionRequestMessages$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequestMessages$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequestMessages$Outbound` instead. */
+ type Outbound = AgentsCompletionRequestMessages$Outbound;
+}
+/** @internal */
+export declare const AgentsCompletionRequestToolChoice$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionRequestToolChoice$Outbound = ToolChoice$Outbound | string;
+/** @internal */
+export declare const AgentsCompletionRequestToolChoice$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionRequestToolChoice$ {
+ /** @deprecated use `AgentsCompletionRequestToolChoice$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequestToolChoice$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequestToolChoice$Outbound` instead. */
+ type Outbound = AgentsCompletionRequestToolChoice$Outbound;
+}
+/** @internal */
+export declare const AgentsCompletionRequest$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionRequest$Outbound = {
+ max_tokens?: number | null | undefined;
+ min_tokens?: number | null | undefined;
+ stream: boolean;
+ stop?: string | Array | undefined;
+ random_seed?: number | null | undefined;
+ messages: Array<(UserMessage$Outbound & {
+ role: "user";
+ }) | (AssistantMessage$Outbound & {
+ role: "assistant";
+ }) | (ToolMessage$Outbound & {
+ role: "tool";
+ })>;
+ response_format?: ResponseFormat$Outbound | undefined;
+ tools?: Array | null | undefined;
+ tool_choice?: ToolChoice$Outbound | string | undefined;
+ agent_id: string;
+};
+/** @internal */
+export declare const AgentsCompletionRequest$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionRequest$ {
+ /** @deprecated use `AgentsCompletionRequest$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequest$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionRequest$Outbound` instead. */
+ type Outbound = AgentsCompletionRequest$Outbound;
+}
+//# sourceMappingURL=agentscompletionrequest.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.d.ts.map b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.d.ts.map
new file mode 100644
index 0000000000..e75e39f301
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentscompletionrequest.d.ts","sourceRoot":"","sources":["../../src/models/components/agentscompletionrequest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EACL,gBAAgB,EAEhB,yBAAyB,EAE1B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,cAAc,EAEd,uBAAuB,EAExB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,IAAI,EAEJ,aAAa,EAEd,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,UAAU,EAEV,mBAAmB,EAEpB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,cAAc,EAGf,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,WAAW,EAEX,oBAAoB,EAErB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,WAAW,EAEX,oBAAoB,EAErB,MAAM,kBAAkB,CAAC;AAE1B;;GAEG;AACH,MAAM,MAAM,2BAA2B,GAAG,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;AAEjE,MAAM,MAAM,+BAA+B,GACvC,CAAC,WAAW,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC,GAChC,CAAC,gBAAgB,GAAG;IAAE,IAAI,EAAE,WAAW,CAAA;CAA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B,GAAG,MAAM,GAAG,SAAS,CAAC;IACvD,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,sCAAsC,EAAE,CAAC,CAAC,OAAO,CAC5D,gCAAgC,EAChC,CAAC,CAAC,UAAU,EACZ,uBAAuB,CA0CvB,CAAC;AAEH;;;GAGG;AACH,yBAAiB,wBAAwB,CAAC;IACxC,uEAAuE;IAChE,MAAM,aAAa,2DAAwC,CAAC;IACnE,wEAAwE;IACjE,MAAM,cAAc,oFAAyC,CAAC;IACrE,kEAAkE;IAClE,KAAY,QAAQ,GAAG,gCAAgC,CAAC;CACzD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.js b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.js
new file mode 100644
index 0000000000..882ccc5dcd
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.js
@@ -0,0 +1,175 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.AgentsCompletionRequest$ = exports.AgentsCompletionRequest$outboundSchema = exports.AgentsCompletionRequest$inboundSchema = exports.AgentsCompletionRequestToolChoice$ = exports.AgentsCompletionRequestToolChoice$outboundSchema = exports.AgentsCompletionRequestToolChoice$inboundSchema = exports.AgentsCompletionRequestMessages$ = exports.AgentsCompletionRequestMessages$outboundSchema = exports.AgentsCompletionRequestMessages$inboundSchema = exports.AgentsCompletionRequestStop$ = exports.AgentsCompletionRequestStop$outboundSchema = exports.AgentsCompletionRequestStop$inboundSchema = void 0;
+const z = __importStar(require("zod"));
+const primitives_js_1 = require("../../lib/primitives.js");
+const assistantmessage_js_1 = require("./assistantmessage.js");
+const responseformat_js_1 = require("./responseformat.js");
+const tool_js_1 = require("./tool.js");
+const toolchoice_js_1 = require("./toolchoice.js");
+const toolchoiceenum_js_1 = require("./toolchoiceenum.js");
+const toolmessage_js_1 = require("./toolmessage.js");
+const usermessage_js_1 = require("./usermessage.js");
+/** @internal */
+exports.AgentsCompletionRequestStop$inboundSchema = z.union([z.string(), z.array(z.string())]);
+/** @internal */
+exports.AgentsCompletionRequestStop$outboundSchema = z.union([z.string(), z.array(z.string())]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionRequestStop$;
+(function (AgentsCompletionRequestStop$) {
+ /** @deprecated use `AgentsCompletionRequestStop$inboundSchema` instead. */
+ AgentsCompletionRequestStop$.inboundSchema = exports.AgentsCompletionRequestStop$inboundSchema;
+ /** @deprecated use `AgentsCompletionRequestStop$outboundSchema` instead. */
+ AgentsCompletionRequestStop$.outboundSchema = exports.AgentsCompletionRequestStop$outboundSchema;
+})(AgentsCompletionRequestStop$ || (exports.AgentsCompletionRequestStop$ = AgentsCompletionRequestStop$ = {}));
+/** @internal */
+exports.AgentsCompletionRequestMessages$inboundSchema = z.union([
+ usermessage_js_1.UserMessage$inboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({ role: v.role }))),
+ assistantmessage_js_1.AssistantMessage$inboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$inboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({ role: v.role }))),
+]);
+/** @internal */
+exports.AgentsCompletionRequestMessages$outboundSchema = z.union([
+ usermessage_js_1.UserMessage$outboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({ role: v.role }))),
+ assistantmessage_js_1.AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$outboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({ role: v.role }))),
+]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionRequestMessages$;
+(function (AgentsCompletionRequestMessages$) {
+ /** @deprecated use `AgentsCompletionRequestMessages$inboundSchema` instead. */
+ AgentsCompletionRequestMessages$.inboundSchema = exports.AgentsCompletionRequestMessages$inboundSchema;
+ /** @deprecated use `AgentsCompletionRequestMessages$outboundSchema` instead. */
+ AgentsCompletionRequestMessages$.outboundSchema = exports.AgentsCompletionRequestMessages$outboundSchema;
+})(AgentsCompletionRequestMessages$ || (exports.AgentsCompletionRequestMessages$ = AgentsCompletionRequestMessages$ = {}));
+/** @internal */
+exports.AgentsCompletionRequestToolChoice$inboundSchema = z.union([toolchoice_js_1.ToolChoice$inboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$inboundSchema]);
+/** @internal */
+exports.AgentsCompletionRequestToolChoice$outboundSchema = z.union([toolchoice_js_1.ToolChoice$outboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$outboundSchema]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionRequestToolChoice$;
+(function (AgentsCompletionRequestToolChoice$) {
+ /** @deprecated use `AgentsCompletionRequestToolChoice$inboundSchema` instead. */
+ AgentsCompletionRequestToolChoice$.inboundSchema = exports.AgentsCompletionRequestToolChoice$inboundSchema;
+ /** @deprecated use `AgentsCompletionRequestToolChoice$outboundSchema` instead. */
+ AgentsCompletionRequestToolChoice$.outboundSchema = exports.AgentsCompletionRequestToolChoice$outboundSchema;
+})(AgentsCompletionRequestToolChoice$ || (exports.AgentsCompletionRequestToolChoice$ = AgentsCompletionRequestToolChoice$ = {}));
+/** @internal */
+exports.AgentsCompletionRequest$inboundSchema = z.object({
+ max_tokens: z.nullable(z.number().int()).optional(),
+ min_tokens: z.nullable(z.number().int()).optional(),
+ stream: z.boolean().default(false),
+ stop: z.union([z.string(), z.array(z.string())]).optional(),
+ random_seed: z.nullable(z.number().int()).optional(),
+ messages: z.array(z.union([
+ usermessage_js_1.UserMessage$inboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({
+ role: v.role,
+ }))),
+ assistantmessage_js_1.AssistantMessage$inboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$inboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({
+ role: v.role,
+ }))),
+ ])),
+ response_format: responseformat_js_1.ResponseFormat$inboundSchema.optional(),
+ tools: z.nullable(z.array(tool_js_1.Tool$inboundSchema)).optional(),
+ tool_choice: z.union([toolchoice_js_1.ToolChoice$inboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$inboundSchema])
+ .optional(),
+ agent_id: z.string(),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ "max_tokens": "maxTokens",
+ "min_tokens": "minTokens",
+ "random_seed": "randomSeed",
+ "response_format": "responseFormat",
+ "tool_choice": "toolChoice",
+ "agent_id": "agentId",
+ });
+});
+/** @internal */
+exports.AgentsCompletionRequest$outboundSchema = z.object({
+ maxTokens: z.nullable(z.number().int()).optional(),
+ minTokens: z.nullable(z.number().int()).optional(),
+ stream: z.boolean().default(false),
+ stop: z.union([z.string(), z.array(z.string())]).optional(),
+ randomSeed: z.nullable(z.number().int()).optional(),
+ messages: z.array(z.union([
+ usermessage_js_1.UserMessage$outboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({
+ role: v.role,
+ }))),
+ assistantmessage_js_1.AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$outboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({
+ role: v.role,
+ }))),
+ ])),
+ responseFormat: responseformat_js_1.ResponseFormat$outboundSchema.optional(),
+ tools: z.nullable(z.array(tool_js_1.Tool$outboundSchema)).optional(),
+ toolChoice: z.union([
+ toolchoice_js_1.ToolChoice$outboundSchema,
+ toolchoiceenum_js_1.ToolChoiceEnum$outboundSchema,
+ ]).optional(),
+ agentId: z.string(),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ maxTokens: "max_tokens",
+ minTokens: "min_tokens",
+ randomSeed: "random_seed",
+ responseFormat: "response_format",
+ toolChoice: "tool_choice",
+ agentId: "agent_id",
+ });
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionRequest$;
+(function (AgentsCompletionRequest$) {
+ /** @deprecated use `AgentsCompletionRequest$inboundSchema` instead. */
+ AgentsCompletionRequest$.inboundSchema = exports.AgentsCompletionRequest$inboundSchema;
+ /** @deprecated use `AgentsCompletionRequest$outboundSchema` instead. */
+ AgentsCompletionRequest$.outboundSchema = exports.AgentsCompletionRequest$outboundSchema;
+})(AgentsCompletionRequest$ || (exports.AgentsCompletionRequest$ = AgentsCompletionRequest$ = {}));
+//# sourceMappingURL=agentscompletionrequest.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.js.map b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.js.map
new file mode 100644
index 0000000000..9d36a86111
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionrequest.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentscompletionrequest.js","sourceRoot":"","sources":["../../src/models/components/agentscompletionrequest.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAC1D,+DAK+B;AAC/B,2DAK6B;AAC7B,uCAKmB;AACnB,mDAKyB;AACzB,2DAI6B;AAC7B,qDAK0B;AAC1B,qDAK0B;AAoD1B,gBAAgB;AACH,QAAA,yCAAyC,GAIlD,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC;AAK/C,gBAAgB;AACH,QAAA,0CAA0C,GAInD,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC;AAE/C;;;GAGG;AACH,IAAiB,4BAA4B,CAO5C;AAPD,WAAiB,4BAA4B;IAC3C,2EAA2E;IAC9D,0CAAa,GAAG,iDAAyC,CAAC;IACvE,4EAA4E;IAC/D,2CAAc,GAAG,kDAA0C,CAAC;AAG3E,CAAC,EAPgB,4BAA4B,4CAA5B,4BAA4B,QAO5C;AAED,gBAAgB;AACH,QAAA,6CAA6C,GAItD,CAAC,CAAC,KAAK,CAAC;IACV,0CAAyB,CAAC,GAAG,CAC3B,CAAC,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAC3E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xC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.d.ts b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.d.ts
new file mode 100644
index 0000000000..525f92b84d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.d.ts
@@ -0,0 +1,152 @@
+import * as z from "zod";
+import { AssistantMessage, AssistantMessage$Outbound } from "./assistantmessage.js";
+import { ResponseFormat, ResponseFormat$Outbound } from "./responseformat.js";
+import { Tool, Tool$Outbound } from "./tool.js";
+import { ToolChoice, ToolChoice$Outbound } from "./toolchoice.js";
+import { ToolChoiceEnum } from "./toolchoiceenum.js";
+import { ToolMessage, ToolMessage$Outbound } from "./toolmessage.js";
+import { UserMessage, UserMessage$Outbound } from "./usermessage.js";
+/**
+ * Stop generation if this token is detected. Or if one of these tokens is detected when providing an array
+ */
+export type AgentsCompletionStreamRequestStop = string | Array;
+export type AgentsCompletionStreamRequestMessages = (UserMessage & {
+ role: "user";
+}) | (AssistantMessage & {
+ role: "assistant";
+}) | (ToolMessage & {
+ role: "tool";
+});
+export type AgentsCompletionStreamRequestToolChoice = ToolChoice | ToolChoiceEnum;
+export type AgentsCompletionStreamRequest = {
+ /**
+ * The maximum number of tokens to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model's context length.
+ */
+ maxTokens?: number | null | undefined;
+ /**
+ * The minimum number of tokens to generate in the completion.
+ */
+ minTokens?: number | null | undefined;
+ stream?: boolean | undefined;
+ /**
+ * Stop generation if this token is detected. Or if one of these tokens is detected when providing an array
+ */
+ stop?: string | Array | undefined;
+ /**
+ * The seed to use for random sampling. If set, different calls will generate deterministic results.
+ */
+ randomSeed?: number | null | undefined;
+ /**
+ * The prompt(s) to generate completions for, encoded as a list of dict with role and content.
+ */
+ messages: Array<(UserMessage & {
+ role: "user";
+ }) | (AssistantMessage & {
+ role: "assistant";
+ }) | (ToolMessage & {
+ role: "tool";
+ })>;
+ responseFormat?: ResponseFormat | undefined;
+ tools?: Array | null | undefined;
+ toolChoice?: ToolChoice | ToolChoiceEnum | undefined;
+ /**
+ * The ID of the agent to use for this completion.
+ */
+ agentId: string;
+};
+/** @internal */
+export declare const AgentsCompletionStreamRequestStop$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionStreamRequestStop$Outbound = string | Array;
+/** @internal */
+export declare const AgentsCompletionStreamRequestStop$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionStreamRequestStop$ {
+ /** @deprecated use `AgentsCompletionStreamRequestStop$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequestStop$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequestStop$Outbound` instead. */
+ type Outbound = AgentsCompletionStreamRequestStop$Outbound;
+}
+/** @internal */
+export declare const AgentsCompletionStreamRequestMessages$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionStreamRequestMessages$Outbound = (UserMessage$Outbound & {
+ role: "user";
+}) | (AssistantMessage$Outbound & {
+ role: "assistant";
+}) | (ToolMessage$Outbound & {
+ role: "tool";
+});
+/** @internal */
+export declare const AgentsCompletionStreamRequestMessages$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionStreamRequestMessages$ {
+ /** @deprecated use `AgentsCompletionStreamRequestMessages$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequestMessages$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequestMessages$Outbound` instead. */
+ type Outbound = AgentsCompletionStreamRequestMessages$Outbound;
+}
+/** @internal */
+export declare const AgentsCompletionStreamRequestToolChoice$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionStreamRequestToolChoice$Outbound = ToolChoice$Outbound | string;
+/** @internal */
+export declare const AgentsCompletionStreamRequestToolChoice$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionStreamRequestToolChoice$ {
+ /** @deprecated use `AgentsCompletionStreamRequestToolChoice$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequestToolChoice$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequestToolChoice$Outbound` instead. */
+ type Outbound = AgentsCompletionStreamRequestToolChoice$Outbound;
+}
+/** @internal */
+export declare const AgentsCompletionStreamRequest$inboundSchema: z.ZodType;
+/** @internal */
+export type AgentsCompletionStreamRequest$Outbound = {
+ max_tokens?: number | null | undefined;
+ min_tokens?: number | null | undefined;
+ stream: boolean;
+ stop?: string | Array | undefined;
+ random_seed?: number | null | undefined;
+ messages: Array<(UserMessage$Outbound & {
+ role: "user";
+ }) | (AssistantMessage$Outbound & {
+ role: "assistant";
+ }) | (ToolMessage$Outbound & {
+ role: "tool";
+ })>;
+ response_format?: ResponseFormat$Outbound | undefined;
+ tools?: Array | null | undefined;
+ tool_choice?: ToolChoice$Outbound | string | undefined;
+ agent_id: string;
+};
+/** @internal */
+export declare const AgentsCompletionStreamRequest$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AgentsCompletionStreamRequest$ {
+ /** @deprecated use `AgentsCompletionStreamRequest$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequest$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AgentsCompletionStreamRequest$Outbound` instead. */
+ type Outbound = AgentsCompletionStreamRequest$Outbound;
+}
+//# sourceMappingURL=agentscompletionstreamrequest.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.d.ts.map b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.d.ts.map
new file mode 100644
index 0000000000..b4cfe5e711
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentscompletionstreamrequest.d.ts","sourceRoot":"","sources":["../../src/models/components/agentscompletionstreamrequest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EACL,gBAAgB,EAEhB,yBAAyB,EAE1B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,cAAc,EAEd,uBAAuB,EAExB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,IAAI,EAEJ,aAAa,EAEd,MAAM,WAAW,CAAC;AACnB,OAAO,EACL,UAAU,EAEV,mBAAmB,EAEpB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,cAAc,EAGf,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,WAAW,EAEX,oBAAoB,EAErB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACL,WAAW,EAEX,oBAAoB,EAErB,MAAM,kBAAkB,CAAC;AAE1B;;GAEG;AACH,MAAM,MAAM,iCAAiC,GAAG,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;AAEvE,MAAM,MAAM,qCAAqC,GAC7C,CAAC,WAAW,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC,GAChC,CAAC,gBAAgB,GAAG;IAAE,IAAI,EAAE,WAAW,CAAA;CAAE,CAAC,GAC1C,CAAC,WAAW,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAErC,MAAM,MAAM,uCAAuC,GAC/C,UAAU,GACV,cAAc,CAAC;AAEnB,M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AAC,CAAC,UAAU,EACZ,6BAA6B,CA0C7B,CAAC;AAEH;;;GAGG;AACH,yBAAiB,8BAA8B,CAAC;IAC9C,6EAA6E;IACtE,MAAM,aAAa,iEAA8C,CAAC;IACzE,8EAA8E;IACvE,MAAM,cAAc,gGAA+C,CAAC;IAC3E,wEAAwE;IACxE,KAAY,QAAQ,GAAG,sCAAsC,CAAC;CAC/D"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.js b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.js
new file mode 100644
index 0000000000..aa7076c94d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.js
@@ -0,0 +1,175 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.AgentsCompletionStreamRequest$ = exports.AgentsCompletionStreamRequest$outboundSchema = exports.AgentsCompletionStreamRequest$inboundSchema = exports.AgentsCompletionStreamRequestToolChoice$ = exports.AgentsCompletionStreamRequestToolChoice$outboundSchema = exports.AgentsCompletionStreamRequestToolChoice$inboundSchema = exports.AgentsCompletionStreamRequestMessages$ = exports.AgentsCompletionStreamRequestMessages$outboundSchema = exports.AgentsCompletionStreamRequestMessages$inboundSchema = exports.AgentsCompletionStreamRequestStop$ = exports.AgentsCompletionStreamRequestStop$outboundSchema = exports.AgentsCompletionStreamRequestStop$inboundSchema = void 0;
+const z = __importStar(require("zod"));
+const primitives_js_1 = require("../../lib/primitives.js");
+const assistantmessage_js_1 = require("./assistantmessage.js");
+const responseformat_js_1 = require("./responseformat.js");
+const tool_js_1 = require("./tool.js");
+const toolchoice_js_1 = require("./toolchoice.js");
+const toolchoiceenum_js_1 = require("./toolchoiceenum.js");
+const toolmessage_js_1 = require("./toolmessage.js");
+const usermessage_js_1 = require("./usermessage.js");
+/** @internal */
+exports.AgentsCompletionStreamRequestStop$inboundSchema = z.union([z.string(), z.array(z.string())]);
+/** @internal */
+exports.AgentsCompletionStreamRequestStop$outboundSchema = z.union([z.string(), z.array(z.string())]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionStreamRequestStop$;
+(function (AgentsCompletionStreamRequestStop$) {
+ /** @deprecated use `AgentsCompletionStreamRequestStop$inboundSchema` instead. */
+ AgentsCompletionStreamRequestStop$.inboundSchema = exports.AgentsCompletionStreamRequestStop$inboundSchema;
+ /** @deprecated use `AgentsCompletionStreamRequestStop$outboundSchema` instead. */
+ AgentsCompletionStreamRequestStop$.outboundSchema = exports.AgentsCompletionStreamRequestStop$outboundSchema;
+})(AgentsCompletionStreamRequestStop$ || (exports.AgentsCompletionStreamRequestStop$ = AgentsCompletionStreamRequestStop$ = {}));
+/** @internal */
+exports.AgentsCompletionStreamRequestMessages$inboundSchema = z.union([
+ usermessage_js_1.UserMessage$inboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({ role: v.role }))),
+ assistantmessage_js_1.AssistantMessage$inboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$inboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({ role: v.role }))),
+]);
+/** @internal */
+exports.AgentsCompletionStreamRequestMessages$outboundSchema = z.union([
+ usermessage_js_1.UserMessage$outboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({ role: v.role }))),
+ assistantmessage_js_1.AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$outboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({ role: v.role }))),
+]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionStreamRequestMessages$;
+(function (AgentsCompletionStreamRequestMessages$) {
+ /** @deprecated use `AgentsCompletionStreamRequestMessages$inboundSchema` instead. */
+ AgentsCompletionStreamRequestMessages$.inboundSchema = exports.AgentsCompletionStreamRequestMessages$inboundSchema;
+ /** @deprecated use `AgentsCompletionStreamRequestMessages$outboundSchema` instead. */
+ AgentsCompletionStreamRequestMessages$.outboundSchema = exports.AgentsCompletionStreamRequestMessages$outboundSchema;
+})(AgentsCompletionStreamRequestMessages$ || (exports.AgentsCompletionStreamRequestMessages$ = AgentsCompletionStreamRequestMessages$ = {}));
+/** @internal */
+exports.AgentsCompletionStreamRequestToolChoice$inboundSchema = z.union([toolchoice_js_1.ToolChoice$inboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$inboundSchema]);
+/** @internal */
+exports.AgentsCompletionStreamRequestToolChoice$outboundSchema = z.union([toolchoice_js_1.ToolChoice$outboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$outboundSchema]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionStreamRequestToolChoice$;
+(function (AgentsCompletionStreamRequestToolChoice$) {
+ /** @deprecated use `AgentsCompletionStreamRequestToolChoice$inboundSchema` instead. */
+ AgentsCompletionStreamRequestToolChoice$.inboundSchema = exports.AgentsCompletionStreamRequestToolChoice$inboundSchema;
+ /** @deprecated use `AgentsCompletionStreamRequestToolChoice$outboundSchema` instead. */
+ AgentsCompletionStreamRequestToolChoice$.outboundSchema = exports.AgentsCompletionStreamRequestToolChoice$outboundSchema;
+})(AgentsCompletionStreamRequestToolChoice$ || (exports.AgentsCompletionStreamRequestToolChoice$ = AgentsCompletionStreamRequestToolChoice$ = {}));
+/** @internal */
+exports.AgentsCompletionStreamRequest$inboundSchema = z.object({
+ max_tokens: z.nullable(z.number().int()).optional(),
+ min_tokens: z.nullable(z.number().int()).optional(),
+ stream: z.boolean().default(true),
+ stop: z.union([z.string(), z.array(z.string())]).optional(),
+ random_seed: z.nullable(z.number().int()).optional(),
+ messages: z.array(z.union([
+ usermessage_js_1.UserMessage$inboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({
+ role: v.role,
+ }))),
+ assistantmessage_js_1.AssistantMessage$inboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$inboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({
+ role: v.role,
+ }))),
+ ])),
+ response_format: responseformat_js_1.ResponseFormat$inboundSchema.optional(),
+ tools: z.nullable(z.array(tool_js_1.Tool$inboundSchema)).optional(),
+ tool_choice: z.union([toolchoice_js_1.ToolChoice$inboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$inboundSchema])
+ .optional(),
+ agent_id: z.string(),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ "max_tokens": "maxTokens",
+ "min_tokens": "minTokens",
+ "random_seed": "randomSeed",
+ "response_format": "responseFormat",
+ "tool_choice": "toolChoice",
+ "agent_id": "agentId",
+ });
+});
+/** @internal */
+exports.AgentsCompletionStreamRequest$outboundSchema = z.object({
+ maxTokens: z.nullable(z.number().int()).optional(),
+ minTokens: z.nullable(z.number().int()).optional(),
+ stream: z.boolean().default(true),
+ stop: z.union([z.string(), z.array(z.string())]).optional(),
+ randomSeed: z.nullable(z.number().int()).optional(),
+ messages: z.array(z.union([
+ usermessage_js_1.UserMessage$outboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({
+ role: v.role,
+ }))),
+ assistantmessage_js_1.AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$outboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({
+ role: v.role,
+ }))),
+ ])),
+ responseFormat: responseformat_js_1.ResponseFormat$outboundSchema.optional(),
+ tools: z.nullable(z.array(tool_js_1.Tool$outboundSchema)).optional(),
+ toolChoice: z.union([
+ toolchoice_js_1.ToolChoice$outboundSchema,
+ toolchoiceenum_js_1.ToolChoiceEnum$outboundSchema,
+ ]).optional(),
+ agentId: z.string(),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ maxTokens: "max_tokens",
+ minTokens: "min_tokens",
+ randomSeed: "random_seed",
+ responseFormat: "response_format",
+ toolChoice: "tool_choice",
+ agentId: "agent_id",
+ });
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AgentsCompletionStreamRequest$;
+(function (AgentsCompletionStreamRequest$) {
+ /** @deprecated use `AgentsCompletionStreamRequest$inboundSchema` instead. */
+ AgentsCompletionStreamRequest$.inboundSchema = exports.AgentsCompletionStreamRequest$inboundSchema;
+ /** @deprecated use `AgentsCompletionStreamRequest$outboundSchema` instead. */
+ AgentsCompletionStreamRequest$.outboundSchema = exports.AgentsCompletionStreamRequest$outboundSchema;
+})(AgentsCompletionStreamRequest$ || (exports.AgentsCompletionStreamRequest$ = AgentsCompletionStreamRequest$ = {}));
+//# sourceMappingURL=agentscompletionstreamrequest.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.js.map b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.js.map
new file mode 100644
index 0000000000..06cdfe4f14
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/agentscompletionstreamrequest.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"agentscompletionstreamrequest.js","sourceRoot":"","sources":["../../src/models/components/agentscompletionstreamrequest.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAC1D,+DAK+B;AAC/B,2DAK6B;AAC7B,uCAKmB;AACnB,mDAKyB;AACzB,2DAI6B;AAC7B,qDAK0B;AAC1B,qDAK0B;AAmD1B,gBAAgB;AACH,QAAA,+CAA+C,GAIxD,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC;AAK/C,gBAAgB;AACH,QAAA,gDAAgD,GAIzD,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC;AAE/C;;;GAGG;AACH,IAAiB,kCAAkC,CAQlD;AARD,WAAiB,kCAAkC;IACjD,iFAAiF;IACpE,gDAAa,GAAG,uDAA+C,CAAC;IAC7E,kFAAkF;IACrE,iDAAc,GACzB,wDAAgD,CAAC;AAGrD,CAAC,EARgB,kCAAkC,kDAAlC,kCAAkC,QAQlD;AAED,gBAAgB;AACH,QAAA,mDAAmD,GAI5D,CAAC,CAAC,KAAK,CAAC;IACV,0CAAyB,CAAC,GAAG,CAC3B,CAAC,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,SAAS,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,8EAA8E;IACjE,6CAAc,GAAG,oDAA4C,CAAC;AAG7E,CAAC,EAPgB,8BAA8B,8CAA9B,8BAA8B,QAO9C"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.d.ts b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.d.ts
new file mode 100644
index 0000000000..492bbee2bd
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.d.ts
@@ -0,0 +1,52 @@
+import * as z from "zod";
+import { ClosedEnum } from "../../types/enums.js";
+export declare const ArchiveFTModelOutObject: {
+ readonly Model: "model";
+};
+export type ArchiveFTModelOutObject = ClosedEnum;
+export type ArchiveFTModelOut = {
+ id: string;
+ object?: "model" | undefined;
+ archived?: boolean | undefined;
+};
+/** @internal */
+export declare const ArchiveFTModelOutObject$inboundSchema: z.ZodNativeEnum;
+/** @internal */
+export declare const ArchiveFTModelOutObject$outboundSchema: z.ZodNativeEnum;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace ArchiveFTModelOutObject$ {
+ /** @deprecated use `ArchiveFTModelOutObject$inboundSchema` instead. */
+ const inboundSchema: z.ZodNativeEnum<{
+ readonly Model: "model";
+ }>;
+ /** @deprecated use `ArchiveFTModelOutObject$outboundSchema` instead. */
+ const outboundSchema: z.ZodNativeEnum<{
+ readonly Model: "model";
+ }>;
+}
+/** @internal */
+export declare const ArchiveFTModelOut$inboundSchema: z.ZodType;
+/** @internal */
+export type ArchiveFTModelOut$Outbound = {
+ id: string;
+ object: "model";
+ archived: boolean;
+};
+/** @internal */
+export declare const ArchiveFTModelOut$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace ArchiveFTModelOut$ {
+ /** @deprecated use `ArchiveFTModelOut$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `ArchiveFTModelOut$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `ArchiveFTModelOut$Outbound` instead. */
+ type Outbound = ArchiveFTModelOut$Outbound;
+}
+//# sourceMappingURL=archiveftmodelout.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.d.ts.map b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.d.ts.map
new file mode 100644
index 0000000000..8110b9b4cc
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"archiveftmodelout.d.ts","sourceRoot":"","sources":["../../src/models/components/archiveftmodelout.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAElD,eAAO,MAAM,uBAAuB;;CAE1B,CAAC;AACX,MAAM,MAAM,uBAAuB,GAAG,UAAU,CAC9C,OAAO,uBAAuB,CAC/B,CAAC;AAEF,MAAM,MAAM,iBAAiB,GAAG;IAC9B,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC7B,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;CAChC,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,qCAAqC,EAAE,CAAC,CAAC,aAAa,CACjE,OAAO,uBAAuB,CACS,CAAC;AAE1C,gBAAgB;AAChB,eAAO,MAAM,sCAAsC,EAAE,CAAC,CAAC,aAAa,CAClE,OAAO,uBAAuB,CACS,CAAC;AAE1C;;;GAGG;AACH,yBAAiB,wBAAwB,CAAC;IACxC,uEAAuE;IAChE,MAAM,aAAa;;MAAwC,CAAC;IACnE,wEAAwE;IACjE,MAAM,cAAc;;MAAyC,CAAC;CACtE;AAED,gBAAgB;AAChB,eAAO,MAAM,+BAA+B,EAAE,CAAC,CAAC,OAAO,CACrD,iBAAiB,EACjB,CAAC,CAAC,UAAU,EACZ,OAAO,CAKP,CAAC;AAEH,gBAAgB;AAChB,MAAM,MAAM,0BAA0B,GAAG;IACvC,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,OAAO,CAAC;IAChB,QAAQ,EAAE,OAAO,CAAC;CACnB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,gCAAgC,EAAE,CAAC,CAAC,OAAO,CACtD,0BAA0B,EAC1B,CAAC,CAAC,UAAU,EACZ,iBAAiB,CAKjB,CAAC;AAEH;;;GAGG;AACH,yBAAiB,kBAAkB,CAAC;IAClC,iEAAiE;IAC1D,MAAM,aAAa,qDAAkC,CAAC;IAC7D,kEAAkE;IAC3D,MAAM,cAAc,wEAAmC,CAAC;IAC/D,4DAA4D;IAC5D,KAAY,QAAQ,GAAG,0BAA0B,CAAC;CACnD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.js b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.js
new file mode 100644
index 0000000000..2348a73e2d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.js
@@ -0,0 +1,72 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.ArchiveFTModelOut$ = exports.ArchiveFTModelOut$outboundSchema = exports.ArchiveFTModelOut$inboundSchema = exports.ArchiveFTModelOutObject$ = exports.ArchiveFTModelOutObject$outboundSchema = exports.ArchiveFTModelOutObject$inboundSchema = exports.ArchiveFTModelOutObject = void 0;
+const z = __importStar(require("zod"));
+exports.ArchiveFTModelOutObject = {
+ Model: "model",
+};
+/** @internal */
+exports.ArchiveFTModelOutObject$inboundSchema = z.nativeEnum(exports.ArchiveFTModelOutObject);
+/** @internal */
+exports.ArchiveFTModelOutObject$outboundSchema = exports.ArchiveFTModelOutObject$inboundSchema;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var ArchiveFTModelOutObject$;
+(function (ArchiveFTModelOutObject$) {
+ /** @deprecated use `ArchiveFTModelOutObject$inboundSchema` instead. */
+ ArchiveFTModelOutObject$.inboundSchema = exports.ArchiveFTModelOutObject$inboundSchema;
+ /** @deprecated use `ArchiveFTModelOutObject$outboundSchema` instead. */
+ ArchiveFTModelOutObject$.outboundSchema = exports.ArchiveFTModelOutObject$outboundSchema;
+})(ArchiveFTModelOutObject$ || (exports.ArchiveFTModelOutObject$ = ArchiveFTModelOutObject$ = {}));
+/** @internal */
+exports.ArchiveFTModelOut$inboundSchema = z.object({
+ id: z.string(),
+ object: z.literal("model").default("model"),
+ archived: z.boolean().default(true),
+});
+/** @internal */
+exports.ArchiveFTModelOut$outboundSchema = z.object({
+ id: z.string(),
+ object: z.literal("model").default("model"),
+ archived: z.boolean().default(true),
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var ArchiveFTModelOut$;
+(function (ArchiveFTModelOut$) {
+ /** @deprecated use `ArchiveFTModelOut$inboundSchema` instead. */
+ ArchiveFTModelOut$.inboundSchema = exports.ArchiveFTModelOut$inboundSchema;
+ /** @deprecated use `ArchiveFTModelOut$outboundSchema` instead. */
+ ArchiveFTModelOut$.outboundSchema = exports.ArchiveFTModelOut$outboundSchema;
+})(ArchiveFTModelOut$ || (exports.ArchiveFTModelOut$ = ArchiveFTModelOut$ = {}));
+//# sourceMappingURL=archiveftmodelout.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.js.map b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.js.map
new file mode 100644
index 0000000000..b274a7d894
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/archiveftmodelout.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"archiveftmodelout.js","sourceRoot":"","sources":["../../src/models/components/archiveftmodelout.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AAGZ,QAAA,uBAAuB,GAAG;IACrC,KAAK,EAAE,OAAO;CACN,CAAC;AAWX,gBAAgB;AACH,QAAA,qCAAqC,GAE9C,CAAC,CAAC,UAAU,CAAC,+BAAuB,CAAC,CAAC;AAE1C,gBAAgB;AACH,QAAA,sCAAsC,GAE/C,6CAAqC,CAAC;AAE1C;;;GAGG;AACH,IAAiB,wBAAwB,CAKxC;AALD,WAAiB,wBAAwB;IACvC,uEAAuE;IAC1D,sCAAa,GAAG,6CAAqC,CAAC;IACnE,wEAAwE;IAC3D,uCAAc,GAAG,8CAAsC,CAAC;AACvE,CAAC,EALgB,wBAAwB,wCAAxB,wBAAwB,QAKxC;AAED,gBAAgB;AACH,QAAA,+BAA+B,GAIxC,CAAC,CAAC,MAAM,CAAC;IACX,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE;IACd,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;IAC3C,QAAQ,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;CACpC,CAAC,CAAC;AASH,gBAAgB;AACH,QAAA,gCAAgC,GAIzC,CAAC,CAAC,MAAM,CAAC;IACX,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE;IACd,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC;IAC3C,QAAQ,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;CACpC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,kBAAkB,CAOlC;AAPD,WAAiB,kBAAkB;IACjC,iEAAiE;IACpD,gCAAa,GAAG,uCAA+B,CAAC;IAC7D,kEAAkE;IACrD,iCAAc,GAAG,wCAAgC,CAAC;AAGjE,CAAC,EAPgB,kBAAkB,kCAAlB,kBAAkB,QAOlC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/assistantmessage.d.ts b/node_modules/@mistralai/mistralai/models/components/assistantmessage.d.ts
new file mode 100644
index 0000000000..a9d6a46371
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/assistantmessage.d.ts
@@ -0,0 +1,58 @@
+import * as z from "zod";
+import { ClosedEnum } from "../../types/enums.js";
+import { ToolCall, ToolCall$Outbound } from "./toolcall.js";
+export declare const AssistantMessageRole: {
+ readonly Assistant: "assistant";
+};
+export type AssistantMessageRole = ClosedEnum;
+export type AssistantMessage = {
+ content?: string | null | undefined;
+ toolCalls?: Array | null | undefined;
+ /**
+ * Set this to `true` when adding an assistant message as prefix to condition the model response. The role of the prefix message is to force the model to start its answer by the content of the message.
+ */
+ prefix?: boolean | undefined;
+ role?: AssistantMessageRole | undefined;
+};
+/** @internal */
+export declare const AssistantMessageRole$inboundSchema: z.ZodNativeEnum;
+/** @internal */
+export declare const AssistantMessageRole$outboundSchema: z.ZodNativeEnum;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AssistantMessageRole$ {
+ /** @deprecated use `AssistantMessageRole$inboundSchema` instead. */
+ const inboundSchema: z.ZodNativeEnum<{
+ readonly Assistant: "assistant";
+ }>;
+ /** @deprecated use `AssistantMessageRole$outboundSchema` instead. */
+ const outboundSchema: z.ZodNativeEnum<{
+ readonly Assistant: "assistant";
+ }>;
+}
+/** @internal */
+export declare const AssistantMessage$inboundSchema: z.ZodType;
+/** @internal */
+export type AssistantMessage$Outbound = {
+ content?: string | null | undefined;
+ tool_calls?: Array | null | undefined;
+ prefix: boolean;
+ role: string;
+};
+/** @internal */
+export declare const AssistantMessage$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace AssistantMessage$ {
+ /** @deprecated use `AssistantMessage$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `AssistantMessage$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `AssistantMessage$Outbound` instead. */
+ type Outbound = AssistantMessage$Outbound;
+}
+//# sourceMappingURL=assistantmessage.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/assistantmessage.d.ts.map b/node_modules/@mistralai/mistralai/models/components/assistantmessage.d.ts.map
new file mode 100644
index 0000000000..bb8807acbf
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/assistantmessage.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"assistantmessage.d.ts","sourceRoot":"","sources":["../../src/models/components/assistantmessage.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EACL,QAAQ,EAER,iBAAiB,EAElB,MAAM,eAAe,CAAC;AAEvB,eAAO,MAAM,oBAAoB;;CAEvB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C;AAEH;;;GAGG;AACH,yBAAiB,iBAAiB,CAAC;IACjC,gEAAgE;IACzD,MAAM,aAAa,oDAAiC,CAAC;IAC5D,iEAAiE;IAC1D,MAAM,cAAc,sEAAkC,CAAC;IAC9D,2DAA2D;IAC3D,KAAY,QAAQ,GAAG,yBAAyB,CAAC;CAClD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/assistantmessage.js b/node_modules/@mistralai/mistralai/models/components/assistantmessage.js
new file mode 100644
index 0000000000..caba840bf5
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/assistantmessage.js
@@ -0,0 +1,84 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.AssistantMessage$ = exports.AssistantMessage$outboundSchema = exports.AssistantMessage$inboundSchema = exports.AssistantMessageRole$ = exports.AssistantMessageRole$outboundSchema = exports.AssistantMessageRole$inboundSchema = exports.AssistantMessageRole = void 0;
+const z = __importStar(require("zod"));
+const primitives_js_1 = require("../../lib/primitives.js");
+const toolcall_js_1 = require("./toolcall.js");
+exports.AssistantMessageRole = {
+ Assistant: "assistant",
+};
+/** @internal */
+exports.AssistantMessageRole$inboundSchema = z.nativeEnum(exports.AssistantMessageRole);
+/** @internal */
+exports.AssistantMessageRole$outboundSchema = exports.AssistantMessageRole$inboundSchema;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AssistantMessageRole$;
+(function (AssistantMessageRole$) {
+ /** @deprecated use `AssistantMessageRole$inboundSchema` instead. */
+ AssistantMessageRole$.inboundSchema = exports.AssistantMessageRole$inboundSchema;
+ /** @deprecated use `AssistantMessageRole$outboundSchema` instead. */
+ AssistantMessageRole$.outboundSchema = exports.AssistantMessageRole$outboundSchema;
+})(AssistantMessageRole$ || (exports.AssistantMessageRole$ = AssistantMessageRole$ = {}));
+/** @internal */
+exports.AssistantMessage$inboundSchema = z.object({
+ content: z.nullable(z.string()).optional(),
+ tool_calls: z.nullable(z.array(toolcall_js_1.ToolCall$inboundSchema)).optional(),
+ prefix: z.boolean().default(false),
+ role: exports.AssistantMessageRole$inboundSchema.default("assistant"),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ "tool_calls": "toolCalls",
+ });
+});
+/** @internal */
+exports.AssistantMessage$outboundSchema = z.object({
+ content: z.nullable(z.string()).optional(),
+ toolCalls: z.nullable(z.array(toolcall_js_1.ToolCall$outboundSchema)).optional(),
+ prefix: z.boolean().default(false),
+ role: exports.AssistantMessageRole$outboundSchema.default("assistant"),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ toolCalls: "tool_calls",
+ });
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var AssistantMessage$;
+(function (AssistantMessage$) {
+ /** @deprecated use `AssistantMessage$inboundSchema` instead. */
+ AssistantMessage$.inboundSchema = exports.AssistantMessage$inboundSchema;
+ /** @deprecated use `AssistantMessage$outboundSchema` instead. */
+ AssistantMessage$.outboundSchema = exports.AssistantMessage$outboundSchema;
+})(AssistantMessage$ || (exports.AssistantMessage$ = AssistantMessage$ = {}));
+//# sourceMappingURL=assistantmessage.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/assistantmessage.js.map b/node_modules/@mistralai/mistralai/models/components/assistantmessage.js.map
new file mode 100644
index 0000000000..e6ccb70a26
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/assistantmessage.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"assistantmessage.js","sourceRoot":"","sources":["../../src/models/components/assistantmessage.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAE1D,+CAKuB;AAEV,QAAA,oBAAoB,GAAG;IAClC,SAAS,EAAE,WAAW;CACd,CAAC;AAaX,gBAAgB;AACH,QAAA,kCAAkC,GAE3C,CAAC,CAAC,UAAU,CAAC,4BAAoB,CAAC,CAAC;AAEvC,gBAAgB;AACH,QAAA,mCAAmC,GAE5C,0CAAkC,CAAC;AAEvC;;;GAGG;AACH,IAAiB,qBAAqB,CAKrC;AALD,WAAiB,qBAAqB;IACpC,oEAAoE;IACvD,mCAAa,GAAG,0CAAkC,CAAC;IAChE,qEAAqE;IACxD,oCAAc,GAAG,2CAAmC,CAAC;AACpE,CAAC,EALgB,qBAAqB,qCAArB,qBAAqB,QAKrC;AAED,gBAAgB;AACH,QAAA,8BAA8B,GAIvC,CAAC,CAAC,MAAM,CAAC;IACX,OAAO,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IAC1C,UAAU,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,oCAAsB,CAAC,CAAC,CAAC,QAAQ,EAAE;IAClE,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC;IAClC,IAAI,EAAE,0CAAkC,CAAC,OAAO,CAAC,WAAW,CAAC;CAC9D,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,YAAY,EAAE,WAAW;KAC1B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAUH,gBAAgB;AACH,QAAA,+BAA+B,GAIxC,CAAC,CAAC,MAAM,CAAC;IACX,OAAO,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IAC1C,SAAS,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,qCAAuB,CAAC,CAAC,CAAC,QAAQ,EAAE;IAClE,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC;IAClC,IAAI,EAAE,2CAAmC,CAAC,OAAO,CAAC,WAAW,CAAC;CAC/D,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,SAAS,EAAE,YAAY;KACxB,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,iBAAiB,CAOjC;AAPD,WAAiB,iBAAiB;IAChC,gEAAgE;IACnD,+BAAa,GAAG,sCAA8B,CAAC;IAC5D,iEAAiE;IACpD,gCAAc,GAAG,uCAA+B,CAAC;AAGhE,CAAC,EAPgB,iBAAiB,iCAAjB,iBAAiB,QAOjC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/basemodelcard.d.ts b/node_modules/@mistralai/mistralai/models/components/basemodelcard.d.ts
new file mode 100644
index 0000000000..0c97ba5cc6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/basemodelcard.d.ts
@@ -0,0 +1,46 @@
+import * as z from "zod";
+import { ModelCapabilities, ModelCapabilities$Outbound } from "./modelcapabilities.js";
+export type BaseModelCard = {
+ id: string;
+ object?: string | undefined;
+ created?: number | undefined;
+ ownedBy?: string | undefined;
+ name?: string | null | undefined;
+ description?: string | null | undefined;
+ maxContextLength?: number | undefined;
+ aliases?: Array | undefined;
+ deprecation?: Date | null | undefined;
+ capabilities: ModelCapabilities;
+ type?: "base" | undefined;
+};
+/** @internal */
+export declare const BaseModelCard$inboundSchema: z.ZodType;
+/** @internal */
+export type BaseModelCard$Outbound = {
+ id: string;
+ object: string;
+ created?: number | undefined;
+ owned_by: string;
+ name?: string | null | undefined;
+ description?: string | null | undefined;
+ max_context_length: number;
+ aliases?: Array | undefined;
+ deprecation?: string | null | undefined;
+ capabilities: ModelCapabilities$Outbound;
+ type: "base";
+};
+/** @internal */
+export declare const BaseModelCard$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace BaseModelCard$ {
+ /** @deprecated use `BaseModelCard$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `BaseModelCard$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `BaseModelCard$Outbound` instead. */
+ type Outbound = BaseModelCard$Outbound;
+}
+//# sourceMappingURL=basemodelcard.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/basemodelcard.d.ts.map b/node_modules/@mistralai/mistralai/models/components/basemodelcard.d.ts.map
new file mode 100644
index 0000000000..23abcfdc73
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/basemodelcard.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"basemodelcard.d.ts","sourceRoot":"","sources":["../../src/models/components/basemodelcard.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EACL,iBAAiB,EAEjB,0BAA0B,EAE3B,MAAM,wBAAwB,CAAC;AAEhC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AE,MAAM,CAAC;CACd,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,4BAA4B,EAAE,CAAC,CAAC,OAAO,CAClD,sBAAsB,EACtB,CAAC,CAAC,UAAU,EACZ,aAAa,CAkBb,CAAC;AAEH;;;GAGG;AACH,yBAAiB,cAAc,CAAC;IAC9B,6DAA6D;IACtD,MAAM,aAAa,iDAA8B,CAAC;IACzD,8DAA8D;IACvD,MAAM,cAAc,gEAA+B,CAAC;IAC3D,wDAAwD;IACxD,KAAY,QAAQ,GAAG,sBAAsB,CAAC;CAC/C"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/basemodelcard.js b/node_modules/@mistralai/mistralai/models/components/basemodelcard.js
new file mode 100644
index 0000000000..b48bed1787
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/basemodelcard.js
@@ -0,0 +1,82 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.BaseModelCard$ = exports.BaseModelCard$outboundSchema = exports.BaseModelCard$inboundSchema = void 0;
+const z = __importStar(require("zod"));
+const primitives_js_1 = require("../../lib/primitives.js");
+const modelcapabilities_js_1 = require("./modelcapabilities.js");
+/** @internal */
+exports.BaseModelCard$inboundSchema = z.object({
+ id: z.string(),
+ object: z.string().default("model"),
+ created: z.number().int().optional(),
+ owned_by: z.string().default("mistralai"),
+ name: z.nullable(z.string()).optional(),
+ description: z.nullable(z.string()).optional(),
+ max_context_length: z.number().int().default(32768),
+ aliases: z.array(z.string()).optional(),
+ deprecation: z.nullable(z.string().datetime({ offset: true }).transform(v => new Date(v))).optional(),
+ capabilities: modelcapabilities_js_1.ModelCapabilities$inboundSchema,
+ type: z.literal("base").default("base"),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ "owned_by": "ownedBy",
+ "max_context_length": "maxContextLength",
+ });
+});
+/** @internal */
+exports.BaseModelCard$outboundSchema = z.object({
+ id: z.string(),
+ object: z.string().default("model"),
+ created: z.number().int().optional(),
+ ownedBy: z.string().default("mistralai"),
+ name: z.nullable(z.string()).optional(),
+ description: z.nullable(z.string()).optional(),
+ maxContextLength: z.number().int().default(32768),
+ aliases: z.array(z.string()).optional(),
+ deprecation: z.nullable(z.date().transform(v => v.toISOString())).optional(),
+ capabilities: modelcapabilities_js_1.ModelCapabilities$outboundSchema,
+ type: z.literal("base").default("base"),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ ownedBy: "owned_by",
+ maxContextLength: "max_context_length",
+ });
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var BaseModelCard$;
+(function (BaseModelCard$) {
+ /** @deprecated use `BaseModelCard$inboundSchema` instead. */
+ BaseModelCard$.inboundSchema = exports.BaseModelCard$inboundSchema;
+ /** @deprecated use `BaseModelCard$outboundSchema` instead. */
+ BaseModelCard$.outboundSchema = exports.BaseModelCard$outboundSchema;
+})(BaseModelCard$ || (exports.BaseModelCard$ = BaseModelCard$ = {}));
+//# sourceMappingURL=basemodelcard.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/basemodelcard.js.map b/node_modules/@mistralai/mistralai/models/components/basemodelcard.js.map
new file mode 100644
index 0000000000..5c8c1341c6
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/basemodelcard.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"basemodelcard.js","sourceRoot":"","sources":["../../src/models/components/basemodelcard.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAC1D,iEAKgC;AAgBhC,gBAAgB;AACH,QAAA,2BAA2B,GAIpC,CAAC,CAAC,MAAM,CAAC;IACX,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE;IACd,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC;IACnC,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACpC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,CAAC,WAAW,CAAC;IACzC,IAAI,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACvC,WAAW,EAAE,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IAC9C,kBAAkB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC;IACnD,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACvC,WAAW,EAAE,CAAC,CAAC,QAAQ,CACrB,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,SA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AAC,CAAC,CAAC,QAAQ,EAAE;IAC5E,YAAY,EAAE,uDAAgC;IAC9C,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,MAAe,CAAC;CACjD,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,OAAO,EAAE,UAAU;QACnB,gBAAgB,EAAE,oBAAoB;KACvC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,cAAc,CAO9B;AAPD,WAAiB,cAAc;IAC7B,6DAA6D;IAChD,4BAAa,GAAG,mCAA2B,CAAC;IACzD,8DAA8D;IACjD,6BAAc,GAAG,oCAA4B,CAAC;AAG7D,CAAC,EAPgB,cAAc,8BAAd,cAAc,QAO9B"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.d.ts b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.d.ts
new file mode 100644
index 0000000000..ee635f6d37
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.d.ts
@@ -0,0 +1,65 @@
+import * as z from "zod";
+import { ClosedEnum } from "../../types/enums.js";
+import { AssistantMessage, AssistantMessage$Outbound } from "./assistantmessage.js";
+export declare const FinishReason: {
+ readonly Stop: "stop";
+ readonly Length: "length";
+ readonly ModelLength: "model_length";
+ readonly Error: "error";
+ readonly ToolCalls: "tool_calls";
+};
+export type FinishReason = ClosedEnum;
+export type ChatCompletionChoice = {
+ index: number;
+ message: AssistantMessage;
+ finishReason: FinishReason;
+};
+/** @internal */
+export declare const FinishReason$inboundSchema: z.ZodNativeEnum;
+/** @internal */
+export declare const FinishReason$outboundSchema: z.ZodNativeEnum;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace FinishReason$ {
+ /** @deprecated use `FinishReason$inboundSchema` instead. */
+ const inboundSchema: z.ZodNativeEnum<{
+ readonly Stop: "stop";
+ readonly Length: "length";
+ readonly ModelLength: "model_length";
+ readonly Error: "error";
+ readonly ToolCalls: "tool_calls";
+ }>;
+ /** @deprecated use `FinishReason$outboundSchema` instead. */
+ const outboundSchema: z.ZodNativeEnum<{
+ readonly Stop: "stop";
+ readonly Length: "length";
+ readonly ModelLength: "model_length";
+ readonly Error: "error";
+ readonly ToolCalls: "tool_calls";
+ }>;
+}
+/** @internal */
+export declare const ChatCompletionChoice$inboundSchema: z.ZodType;
+/** @internal */
+export type ChatCompletionChoice$Outbound = {
+ index: number;
+ message: AssistantMessage$Outbound;
+ finish_reason: string;
+};
+/** @internal */
+export declare const ChatCompletionChoice$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace ChatCompletionChoice$ {
+ /** @deprecated use `ChatCompletionChoice$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionChoice$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionChoice$Outbound` instead. */
+ type Outbound = ChatCompletionChoice$Outbound;
+}
+//# sourceMappingURL=chatcompletionchoice.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.d.ts.map b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.d.ts.map
new file mode 100644
index 0000000000..acf198ce3d
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatcompletionchoice.d.ts","sourceRoot":"","sources":["../../src/models/components/chatcompletionchoice.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EACL,gBAAgB,EAEhB,yBAAy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\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.js b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.js
new file mode 100644
index 0000000000..c26962c13f
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.js
@@ -0,0 +1,86 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.ChatCompletionChoice$ = exports.ChatCompletionChoice$outboundSchema = exports.ChatCompletionChoice$inboundSchema = exports.FinishReason$ = exports.FinishReason$outboundSchema = exports.FinishReason$inboundSchema = exports.FinishReason = void 0;
+const z = __importStar(require("zod"));
+const primitives_js_1 = require("../../lib/primitives.js");
+const assistantmessage_js_1 = require("./assistantmessage.js");
+exports.FinishReason = {
+ Stop: "stop",
+ Length: "length",
+ ModelLength: "model_length",
+ Error: "error",
+ ToolCalls: "tool_calls",
+};
+/** @internal */
+exports.FinishReason$inboundSchema = z.nativeEnum(exports.FinishReason);
+/** @internal */
+exports.FinishReason$outboundSchema = exports.FinishReason$inboundSchema;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var FinishReason$;
+(function (FinishReason$) {
+ /** @deprecated use `FinishReason$inboundSchema` instead. */
+ FinishReason$.inboundSchema = exports.FinishReason$inboundSchema;
+ /** @deprecated use `FinishReason$outboundSchema` instead. */
+ FinishReason$.outboundSchema = exports.FinishReason$outboundSchema;
+})(FinishReason$ || (exports.FinishReason$ = FinishReason$ = {}));
+/** @internal */
+exports.ChatCompletionChoice$inboundSchema = z.object({
+ index: z.number().int(),
+ message: assistantmessage_js_1.AssistantMessage$inboundSchema,
+ finish_reason: exports.FinishReason$inboundSchema,
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ "finish_reason": "finishReason",
+ });
+});
+/** @internal */
+exports.ChatCompletionChoice$outboundSchema = z.object({
+ index: z.number().int(),
+ message: assistantmessage_js_1.AssistantMessage$outboundSchema,
+ finishReason: exports.FinishReason$outboundSchema,
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ finishReason: "finish_reason",
+ });
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var ChatCompletionChoice$;
+(function (ChatCompletionChoice$) {
+ /** @deprecated use `ChatCompletionChoice$inboundSchema` instead. */
+ ChatCompletionChoice$.inboundSchema = exports.ChatCompletionChoice$inboundSchema;
+ /** @deprecated use `ChatCompletionChoice$outboundSchema` instead. */
+ ChatCompletionChoice$.outboundSchema = exports.ChatCompletionChoice$outboundSchema;
+})(ChatCompletionChoice$ || (exports.ChatCompletionChoice$ = ChatCompletionChoice$ = {}));
+//# sourceMappingURL=chatcompletionchoice.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.js.map b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.js.map
new file mode 100644
index 0000000000..ffb8026285
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionchoice.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatcompletionchoice.js","sourceRoot":"","sources":["../../src/models/components/chatcompletionchoice.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAE1D,+DAK+B;AAElB,QAAA,YAAY,GAAG;IAC1B,IAAI,EAAE,MAAM;IACZ,MAAM,EAAE,QAAQ;IAChB,WAAW,EAAE,cAAc;IAC3B,KAAK,EAAE,OAAO;IACd,SAAS,EAAE,YAAY;CACf,CAAC;AASX,gBAAgB;AACH,QAAA,0BAA0B,GACrC,CAAC,CAAC,UAAU,CAAC,oBAAY,CAAC,CAAC;AAE7B,gBAAgB;AACH,QAAA,2BAA2B,GACtC,kCAA0B,CAAC;AAE7B;;;GAGG;AACH,IAAiB,aAAa,CAK7B;AALD,WAAiB,aAAa;IAC5B,4DAA4D;IAC/C,2BAAa,GAAG,kCAA0B,CAAC;IACxD,6DAA6D;IAChD,4BAAc,GAAG,mCAA2B,CAAC;AAC5D,CAAC,EALgB,aAAa,6BAAb,aAAa,QAK7B;AAED,gBAAgB;AACH,QAAA,kCAAkC,GAI3C,CAAC,CAAC,MAAM,CAAC;IACX,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;IACvB,OAAO,EAAE,oDAA8B;IACvC,aAAa,EAAE,kCAA0B;CAC1C,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,eAAe,EAAE,cAAc;KAChC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AASH,gBAAgB;AACH,QAAA,mCAAmC,GAI5C,CAAC,CAAC,MAAM,CAAC;IACX,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE;IACvB,OAAO,EAAE,qDAA+B;IACxC,YAAY,EAAE,mCAA2B;CAC1C,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,YAAY,EAAE,eAAe;KAC9B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,qBAAqB,CAOrC;AAPD,WAAiB,qBAAqB;IACpC,oEAAoE;IACvD,mCAAa,GAAG,0CAAkC,CAAC;IAChE,qEAAqE;IACxD,oCAAc,GAAG,2CAAmC,CAAC;AAGpE,CAAC,EAPgB,qBAAqB,qCAArB,qBAAqB,QAOrC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.d.ts b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.d.ts
new file mode 100644
index 0000000000..95fd93749c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.d.ts
@@ -0,0 +1,179 @@
+import * as z from "zod";
+import { AssistantMessage, AssistantMessage$Outbound } from "./assistantmessage.js";
+import { ResponseFormat, ResponseFormat$Outbound } from "./responseformat.js";
+import { SystemMessage, SystemMessage$Outbound } from "./systemmessage.js";
+import { Tool, Tool$Outbound } from "./tool.js";
+import { ToolChoice, ToolChoice$Outbound } from "./toolchoice.js";
+import { ToolChoiceEnum } from "./toolchoiceenum.js";
+import { ToolMessage, ToolMessage$Outbound } from "./toolmessage.js";
+import { UserMessage, UserMessage$Outbound } from "./usermessage.js";
+/**
+ * Stop generation if this token is detected. Or if one of these tokens is detected when providing an array
+ */
+export type Stop = string | Array;
+export type Messages = (SystemMessage & {
+ role: "system";
+}) | (UserMessage & {
+ role: "user";
+}) | (AssistantMessage & {
+ role: "assistant";
+}) | (ToolMessage & {
+ role: "tool";
+});
+export type ChatCompletionRequestToolChoice = ToolChoice | ToolChoiceEnum;
+export type ChatCompletionRequest = {
+ /**
+ * ID of the model to use. You can use the [List Available Models](/api/#tag/models/operation/list_models_v1_models_get) API to see all of your available models, or see our [Model overview](/models) for model descriptions.
+ */
+ model: string | null;
+ /**
+ * What sampling temperature to use, between 0.0 and 1.0. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. We generally recommend altering this or `top_p` but not both.
+ */
+ temperature?: number | undefined;
+ /**
+ * Nucleus sampling, where the model considers the results of the tokens with `top_p` probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or `temperature` but not both.
+ */
+ topP?: number | undefined;
+ /**
+ * The maximum number of tokens to generate in the completion. The token count of your prompt plus `max_tokens` cannot exceed the model's context length.
+ */
+ maxTokens?: number | null | undefined;
+ /**
+ * The minimum number of tokens to generate in the completion.
+ */
+ minTokens?: number | null | undefined;
+ /**
+ * Whether to stream back partial progress. If set, tokens will be sent as data-only server-side events as they become available, with the stream terminated by a data: [DONE] message. Otherwise, the server will hold the request open until the timeout or until completion, with the response containing the full result as JSON.
+ */
+ stream?: boolean | undefined;
+ /**
+ * Stop generation if this token is detected. Or if one of these tokens is detected when providing an array
+ */
+ stop?: string | Array | undefined;
+ /**
+ * The seed to use for random sampling. If set, different calls will generate deterministic results.
+ */
+ randomSeed?: number | null | undefined;
+ /**
+ * The prompt(s) to generate completions for, encoded as a list of dict with role and content.
+ */
+ messages: Array<(SystemMessage & {
+ role: "system";
+ }) | (UserMessage & {
+ role: "user";
+ }) | (AssistantMessage & {
+ role: "assistant";
+ }) | (ToolMessage & {
+ role: "tool";
+ })>;
+ responseFormat?: ResponseFormat | undefined;
+ tools?: Array | null | undefined;
+ toolChoice?: ToolChoice | ToolChoiceEnum | undefined;
+ /**
+ * Whether to inject a safety prompt before all conversations.
+ */
+ safePrompt?: boolean | undefined;
+};
+/** @internal */
+export declare const Stop$inboundSchema: z.ZodType;
+/** @internal */
+export type Stop$Outbound = string | Array;
+/** @internal */
+export declare const Stop$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace Stop$ {
+ /** @deprecated use `Stop$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `Stop$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `Stop$Outbound` instead. */
+ type Outbound = Stop$Outbound;
+}
+/** @internal */
+export declare const Messages$inboundSchema: z.ZodType;
+/** @internal */
+export type Messages$Outbound = (SystemMessage$Outbound & {
+ role: "system";
+}) | (UserMessage$Outbound & {
+ role: "user";
+}) | (AssistantMessage$Outbound & {
+ role: "assistant";
+}) | (ToolMessage$Outbound & {
+ role: "tool";
+});
+/** @internal */
+export declare const Messages$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace Messages$ {
+ /** @deprecated use `Messages$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `Messages$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `Messages$Outbound` instead. */
+ type Outbound = Messages$Outbound;
+}
+/** @internal */
+export declare const ChatCompletionRequestToolChoice$inboundSchema: z.ZodType;
+/** @internal */
+export type ChatCompletionRequestToolChoice$Outbound = ToolChoice$Outbound | string;
+/** @internal */
+export declare const ChatCompletionRequestToolChoice$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace ChatCompletionRequestToolChoice$ {
+ /** @deprecated use `ChatCompletionRequestToolChoice$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionRequestToolChoice$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionRequestToolChoice$Outbound` instead. */
+ type Outbound = ChatCompletionRequestToolChoice$Outbound;
+}
+/** @internal */
+export declare const ChatCompletionRequest$inboundSchema: z.ZodType;
+/** @internal */
+export type ChatCompletionRequest$Outbound = {
+ model: string | null;
+ temperature: number;
+ top_p: number;
+ max_tokens?: number | null | undefined;
+ min_tokens?: number | null | undefined;
+ stream: boolean;
+ stop?: string | Array | undefined;
+ random_seed?: number | null | undefined;
+ messages: Array<(SystemMessage$Outbound & {
+ role: "system";
+ }) | (UserMessage$Outbound & {
+ role: "user";
+ }) | (AssistantMessage$Outbound & {
+ role: "assistant";
+ }) | (ToolMessage$Outbound & {
+ role: "tool";
+ })>;
+ response_format?: ResponseFormat$Outbound | undefined;
+ tools?: Array | null | undefined;
+ tool_choice?: ToolChoice$Outbound | string | undefined;
+ safe_prompt: boolean;
+};
+/** @internal */
+export declare const ChatCompletionRequest$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace ChatCompletionRequest$ {
+ /** @deprecated use `ChatCompletionRequest$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionRequest$outboundSchema` instead. */
+ const outboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionRequest$Outbound` instead. */
+ type Outbound = ChatCompletionRequest$Outbound;
+}
+//# sourceMappingURL=chatcompletionrequest.d.ts.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.d.ts.map b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.d.ts.map
new file mode 100644
index 0000000000..ca2f6143a7
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.d.ts.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatcompletionrequest.d.ts","sourceRoot":"","sources":["../../src/models/components/chatcompletionrequest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EACL,gBAAgB,EAEhB,yBAAyB,EAE1B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,cAAc,EAEd,uBAAuB,EAExB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,aAAa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eAAO,MAAM,oCAAoC,EAAE,CAAC,CAAC,OAAO,CAC1D,8BAA8B,EAC9B,CAAC,CAAC,UAAU,EACZ,qBAAqB,CAmDrB,CAAC;AAEH;;;GAGG;AACH,yBAAiB,sBAAsB,CAAC;IACtC,qEAAqE;IAC9D,MAAM,aAAa,yDAAsC,CAAC;IACjE,sEAAsE;IAC/D,MAAM,cAAc,gFAAuC,CAAC;IACnE,gEAAgE;IAChE,KAAY,QAAQ,GAAG,8BAA8B,CAAC;CACvD"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.js b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.js
new file mode 100644
index 0000000000..6be95fe08c
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.js
@@ -0,0 +1,197 @@
+"use strict";
+/*
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
+ */
+var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ var desc = Object.getOwnPropertyDescriptor(m, k);
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
+ desc = { enumerable: true, get: function() { return m[k]; } };
+ }
+ Object.defineProperty(o, k2, desc);
+}) : (function(o, m, k, k2) {
+ if (k2 === undefined) k2 = k;
+ o[k2] = m[k];
+}));
+var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
+}) : function(o, v) {
+ o["default"] = v;
+});
+var __importStar = (this && this.__importStar) || function (mod) {
+ if (mod && mod.__esModule) return mod;
+ var result = {};
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
+ __setModuleDefault(result, mod);
+ return result;
+};
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.ChatCompletionRequest$ = exports.ChatCompletionRequest$outboundSchema = exports.ChatCompletionRequest$inboundSchema = exports.ChatCompletionRequestToolChoice$ = exports.ChatCompletionRequestToolChoice$outboundSchema = exports.ChatCompletionRequestToolChoice$inboundSchema = exports.Messages$ = exports.Messages$outboundSchema = exports.Messages$inboundSchema = exports.Stop$ = exports.Stop$outboundSchema = exports.Stop$inboundSchema = void 0;
+const z = __importStar(require("zod"));
+const primitives_js_1 = require("../../lib/primitives.js");
+const assistantmessage_js_1 = require("./assistantmessage.js");
+const responseformat_js_1 = require("./responseformat.js");
+const systemmessage_js_1 = require("./systemmessage.js");
+const tool_js_1 = require("./tool.js");
+const toolchoice_js_1 = require("./toolchoice.js");
+const toolchoiceenum_js_1 = require("./toolchoiceenum.js");
+const toolmessage_js_1 = require("./toolmessage.js");
+const usermessage_js_1 = require("./usermessage.js");
+/** @internal */
+exports.Stop$inboundSchema = z
+ .union([z.string(), z.array(z.string())]);
+/** @internal */
+exports.Stop$outboundSchema = z.union([z.string(), z.array(z.string())]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var Stop$;
+(function (Stop$) {
+ /** @deprecated use `Stop$inboundSchema` instead. */
+ Stop$.inboundSchema = exports.Stop$inboundSchema;
+ /** @deprecated use `Stop$outboundSchema` instead. */
+ Stop$.outboundSchema = exports.Stop$outboundSchema;
+})(Stop$ || (exports.Stop$ = Stop$ = {}));
+/** @internal */
+exports.Messages$inboundSchema = z.union([
+ systemmessage_js_1.SystemMessage$inboundSchema.and(z.object({ role: z.literal("system") }).transform((v) => ({
+ role: v.role,
+ }))),
+ usermessage_js_1.UserMessage$inboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({ role: v.role }))),
+ assistantmessage_js_1.AssistantMessage$inboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$inboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({ role: v.role }))),
+]);
+/** @internal */
+exports.Messages$outboundSchema = z.union([
+ systemmessage_js_1.SystemMessage$outboundSchema.and(z.object({ role: z.literal("system") }).transform((v) => ({
+ role: v.role,
+ }))),
+ usermessage_js_1.UserMessage$outboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({ role: v.role }))),
+ assistantmessage_js_1.AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$outboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({ role: v.role }))),
+]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var Messages$;
+(function (Messages$) {
+ /** @deprecated use `Messages$inboundSchema` instead. */
+ Messages$.inboundSchema = exports.Messages$inboundSchema;
+ /** @deprecated use `Messages$outboundSchema` instead. */
+ Messages$.outboundSchema = exports.Messages$outboundSchema;
+})(Messages$ || (exports.Messages$ = Messages$ = {}));
+/** @internal */
+exports.ChatCompletionRequestToolChoice$inboundSchema = z.union([toolchoice_js_1.ToolChoice$inboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$inboundSchema]);
+/** @internal */
+exports.ChatCompletionRequestToolChoice$outboundSchema = z.union([toolchoice_js_1.ToolChoice$outboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$outboundSchema]);
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var ChatCompletionRequestToolChoice$;
+(function (ChatCompletionRequestToolChoice$) {
+ /** @deprecated use `ChatCompletionRequestToolChoice$inboundSchema` instead. */
+ ChatCompletionRequestToolChoice$.inboundSchema = exports.ChatCompletionRequestToolChoice$inboundSchema;
+ /** @deprecated use `ChatCompletionRequestToolChoice$outboundSchema` instead. */
+ ChatCompletionRequestToolChoice$.outboundSchema = exports.ChatCompletionRequestToolChoice$outboundSchema;
+})(ChatCompletionRequestToolChoice$ || (exports.ChatCompletionRequestToolChoice$ = ChatCompletionRequestToolChoice$ = {}));
+/** @internal */
+exports.ChatCompletionRequest$inboundSchema = z.object({
+ model: z.nullable(z.string()),
+ temperature: z.number().default(0.7),
+ top_p: z.number().default(1),
+ max_tokens: z.nullable(z.number().int()).optional(),
+ min_tokens: z.nullable(z.number().int()).optional(),
+ stream: z.boolean().default(false),
+ stop: z.union([z.string(), z.array(z.string())]).optional(),
+ random_seed: z.nullable(z.number().int()).optional(),
+ messages: z.array(z.union([
+ systemmessage_js_1.SystemMessage$inboundSchema.and(z.object({ role: z.literal("system") }).transform((v) => ({
+ role: v.role,
+ }))),
+ usermessage_js_1.UserMessage$inboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({
+ role: v.role,
+ }))),
+ assistantmessage_js_1.AssistantMessage$inboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$inboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({
+ role: v.role,
+ }))),
+ ])),
+ response_format: responseformat_js_1.ResponseFormat$inboundSchema.optional(),
+ tools: z.nullable(z.array(tool_js_1.Tool$inboundSchema)).optional(),
+ tool_choice: z.union([toolchoice_js_1.ToolChoice$inboundSchema, toolchoiceenum_js_1.ToolChoiceEnum$inboundSchema])
+ .optional(),
+ safe_prompt: z.boolean().default(false),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ "top_p": "topP",
+ "max_tokens": "maxTokens",
+ "min_tokens": "minTokens",
+ "random_seed": "randomSeed",
+ "response_format": "responseFormat",
+ "tool_choice": "toolChoice",
+ "safe_prompt": "safePrompt",
+ });
+});
+/** @internal */
+exports.ChatCompletionRequest$outboundSchema = z.object({
+ model: z.nullable(z.string()),
+ temperature: z.number().default(0.7),
+ topP: z.number().default(1),
+ maxTokens: z.nullable(z.number().int()).optional(),
+ minTokens: z.nullable(z.number().int()).optional(),
+ stream: z.boolean().default(false),
+ stop: z.union([z.string(), z.array(z.string())]).optional(),
+ randomSeed: z.nullable(z.number().int()).optional(),
+ messages: z.array(z.union([
+ systemmessage_js_1.SystemMessage$outboundSchema.and(z.object({ role: z.literal("system") }).transform((v) => ({
+ role: v.role,
+ }))),
+ usermessage_js_1.UserMessage$outboundSchema.and(z.object({ role: z.literal("user") }).transform((v) => ({
+ role: v.role,
+ }))),
+ assistantmessage_js_1.AssistantMessage$outboundSchema.and(z.object({ role: z.literal("assistant") }).transform((v) => ({
+ role: v.role,
+ }))),
+ toolmessage_js_1.ToolMessage$outboundSchema.and(z.object({ role: z.literal("tool") }).transform((v) => ({
+ role: v.role,
+ }))),
+ ])),
+ responseFormat: responseformat_js_1.ResponseFormat$outboundSchema.optional(),
+ tools: z.nullable(z.array(tool_js_1.Tool$outboundSchema)).optional(),
+ toolChoice: z.union([
+ toolchoice_js_1.ToolChoice$outboundSchema,
+ toolchoiceenum_js_1.ToolChoiceEnum$outboundSchema,
+ ]).optional(),
+ safePrompt: z.boolean().default(false),
+}).transform((v) => {
+ return (0, primitives_js_1.remap)(v, {
+ topP: "top_p",
+ maxTokens: "max_tokens",
+ minTokens: "min_tokens",
+ randomSeed: "random_seed",
+ responseFormat: "response_format",
+ toolChoice: "tool_choice",
+ safePrompt: "safe_prompt",
+ });
+});
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+var ChatCompletionRequest$;
+(function (ChatCompletionRequest$) {
+ /** @deprecated use `ChatCompletionRequest$inboundSchema` instead. */
+ ChatCompletionRequest$.inboundSchema = exports.ChatCompletionRequest$inboundSchema;
+ /** @deprecated use `ChatCompletionRequest$outboundSchema` instead. */
+ ChatCompletionRequest$.outboundSchema = exports.ChatCompletionRequest$outboundSchema;
+})(ChatCompletionRequest$ || (exports.ChatCompletionRequest$ = ChatCompletionRequest$ = {}));
+//# sourceMappingURL=chatcompletionrequest.js.map
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.js.map b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.js.map
new file mode 100644
index 0000000000..b60c557ed1
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionrequest.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"chatcompletionrequest.js","sourceRoot":"","sources":["../../src/models/components/chatcompletionrequest.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2DAA0D;AAC1D,+DAK+B;AAC/B,2DAK6B;AAC7B,yDAK4B;AAC5B,uCAKmB;AACnB,mDAKyB;AACzB,2DAI6B;AAC7B,qDAK0B;AAC1B,qDAK0B;AAkE1B,gBAAgB;AACH,QAAA,kBAAkB,GAA2C,CAAC;KACxE,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC;AAK5C,gBAAgB;AACH,QAAA,mBAAmB,GAC9B,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,CAAC,CAAC;AAE7C;;;GAGG;AACH,IAAiB,KAAK,CAOrB;AAPD,WAAiB,KAAK;IACpB,oDAAoD;IACvC,mBAAa,GAAG,0BAAkB,CAAC;IAChD,qDAAqD;IACxC,oBAAc,GAAG,2BAAmB,CAAC;AAGpD,CAAC,EAPgB,KAAK,qBAAL,KAAK,QAOrB;AAED,gBAAgB;AACH,QAAA,sBAAsB,GAI/B,CAAC,CAAC,KAAK,CAAC;IACV,8CAA2B,CAAC,GAAG,CAC7B,CAAC,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QACxD,IAAI,EAAE,CAAC,CAAC,IAAI;KACb,CAAC,CAAC,CACJ;IAC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C1B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,sBAAsB,CAOtC;AAPD,WAAiB,sBAAsB;IACrC,qEAAqE;IACxD,oCAAa,GAAG,2CAAmC,CAAC;IACjE,sEAAsE;IACzD,qCAAc,GAAG,4CAAoC,CAAC;AAGrE,CAAC,EAPgB,sBAAsB,sCAAtB,sBAAsB,QAOtC"}
\ No newline at end of file
diff --git a/node_modules/@mistralai/mistralai/models/components/chatcompletionresponse.d.ts b/node_modules/@mistralai/mistralai/models/components/chatcompletionresponse.d.ts
new file mode 100644
index 0000000000..64381a7de0
--- /dev/null
+++ b/node_modules/@mistralai/mistralai/models/components/chatcompletionresponse.d.ts
@@ -0,0 +1,37 @@
+import * as z from "zod";
+import { ChatCompletionChoice, ChatCompletionChoice$Outbound } from "./chatcompletionchoice.js";
+import { UsageInfo, UsageInfo$Outbound } from "./usageinfo.js";
+export type ChatCompletionResponse = {
+ id: string;
+ object: string;
+ model: string;
+ usage: UsageInfo;
+ created?: number | undefined;
+ choices?: Array | undefined;
+};
+/** @internal */
+export declare const ChatCompletionResponse$inboundSchema: z.ZodType;
+/** @internal */
+export type ChatCompletionResponse$Outbound = {
+ id: string;
+ object: string;
+ model: string;
+ usage: UsageInfo$Outbound;
+ created?: number | undefined;
+ choices?: Array | undefined;
+};
+/** @internal */
+export declare const ChatCompletionResponse$outboundSchema: z.ZodType;
+/**
+ * @internal
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
+ */
+export declare namespace ChatCompletionResponse$ {
+ /** @deprecated use `ChatCompletionResponse$inboundSchema` instead. */
+ const inboundSchema: z.ZodType;
+ /** @deprecated use `ChatCompletionResponse$outboundSchema` instead. */
+ const outboundSchema: z.ZodType