@hasna/evals 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/index.js +8 -3
- package/dist/index.js +7 -7
- package/dist/server/index.js +7 -7
- package/package.json +3 -3
package/dist/cli/index.js
CHANGED
|
@@ -11054,7 +11054,7 @@ async function ensureAllPgDatabases() {
|
|
|
11054
11054
|
}
|
|
11055
11055
|
return results;
|
|
11056
11056
|
}
|
|
11057
|
-
function registerCloudTools(server, serviceName) {
|
|
11057
|
+
function registerCloudTools(server, serviceName, opts = {}) {
|
|
11058
11058
|
server.tool(`${serviceName}_cloud_status`, "Show cloud configuration and connection health", {}, async () => {
|
|
11059
11059
|
const config = getCloudConfig();
|
|
11060
11060
|
const lines = [
|
|
@@ -11087,8 +11087,13 @@ function registerCloudTools(server, serviceName) {
|
|
|
11087
11087
|
isError: true
|
|
11088
11088
|
};
|
|
11089
11089
|
}
|
|
11090
|
-
const local = new SqliteAdapter(getDbPath2(serviceName));
|
|
11090
|
+
const local = new SqliteAdapter(opts.dbPath ?? getDbPath2(serviceName));
|
|
11091
11091
|
const cloud = new PgAdapterAsync(getConnectionString(serviceName));
|
|
11092
|
+
if (opts.migrations?.length) {
|
|
11093
|
+
for (const sql of opts.migrations) {
|
|
11094
|
+
await cloud.run(sql);
|
|
11095
|
+
}
|
|
11096
|
+
}
|
|
11092
11097
|
const tableList = tablesStr ? tablesStr.split(",").map((t) => t.trim()) : listSqliteTables(local);
|
|
11093
11098
|
const results = await syncPush(local, cloud, { tables: tableList });
|
|
11094
11099
|
local.close();
|
|
@@ -11110,7 +11115,7 @@ function registerCloudTools(server, serviceName) {
|
|
|
11110
11115
|
isError: true
|
|
11111
11116
|
};
|
|
11112
11117
|
}
|
|
11113
|
-
const local = new SqliteAdapter(getDbPath2(serviceName));
|
|
11118
|
+
const local = new SqliteAdapter(opts.dbPath ?? getDbPath2(serviceName));
|
|
11114
11119
|
const cloud = new PgAdapterAsync(getConnectionString(serviceName));
|
|
11115
11120
|
let tableList;
|
|
11116
11121
|
if (tablesStr) {
|
package/dist/index.js
CHANGED
|
@@ -19808,7 +19808,7 @@ var AssertObjectSchema = custom((v) => v !== null && (typeof v === "object" || t
|
|
|
19808
19808
|
var ProgressTokenSchema = union([string2(), number2().int()]);
|
|
19809
19809
|
var CursorSchema = string2();
|
|
19810
19810
|
var TaskCreationParamsSchema = looseObject({
|
|
19811
|
-
ttl:
|
|
19811
|
+
ttl: number2().optional(),
|
|
19812
19812
|
pollInterval: number2().optional()
|
|
19813
19813
|
});
|
|
19814
19814
|
var TaskMetadataSchema = object2({
|
|
@@ -19962,7 +19962,8 @@ var ClientCapabilitiesSchema = object2({
|
|
|
19962
19962
|
roots: object2({
|
|
19963
19963
|
listChanged: boolean2().optional()
|
|
19964
19964
|
}).optional(),
|
|
19965
|
-
tasks: ClientTasksCapabilitySchema.optional()
|
|
19965
|
+
tasks: ClientTasksCapabilitySchema.optional(),
|
|
19966
|
+
extensions: record(string2(), AssertObjectSchema).optional()
|
|
19966
19967
|
});
|
|
19967
19968
|
var InitializeRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
19968
19969
|
protocolVersion: string2(),
|
|
@@ -19987,7 +19988,8 @@ var ServerCapabilitiesSchema = object2({
|
|
|
19987
19988
|
tools: object2({
|
|
19988
19989
|
listChanged: boolean2().optional()
|
|
19989
19990
|
}).optional(),
|
|
19990
|
-
tasks: ServerTasksCapabilitySchema.optional()
|
|
19991
|
+
tasks: ServerTasksCapabilitySchema.optional(),
|
|
19992
|
+
extensions: record(string2(), AssertObjectSchema).optional()
|
|
19991
19993
|
});
|
|
19992
19994
|
var InitializeResultSchema = ResultSchema.extend({
|
|
19993
19995
|
protocolVersion: string2(),
|
|
@@ -20102,6 +20104,7 @@ var ResourceSchema = object2({
|
|
|
20102
20104
|
uri: string2(),
|
|
20103
20105
|
description: optional(string2()),
|
|
20104
20106
|
mimeType: optional(string2()),
|
|
20107
|
+
size: optional(number2()),
|
|
20105
20108
|
annotations: AnnotationsSchema.optional(),
|
|
20106
20109
|
_meta: optional(looseObject({}))
|
|
20107
20110
|
});
|
|
@@ -22196,7 +22199,7 @@ class StdioClientTransport {
|
|
|
22196
22199
|
},
|
|
22197
22200
|
stdio: ["pipe", "pipe", this._serverParams.stderr ?? "inherit"],
|
|
22198
22201
|
shell: false,
|
|
22199
|
-
windowsHide: process2.platform === "win32"
|
|
22202
|
+
windowsHide: process2.platform === "win32",
|
|
22200
22203
|
cwd: this._serverParams.cwd
|
|
22201
22204
|
});
|
|
22202
22205
|
this._process.on("error", (error2) => {
|
|
@@ -22288,9 +22291,6 @@ class StdioClientTransport {
|
|
|
22288
22291
|
});
|
|
22289
22292
|
}
|
|
22290
22293
|
}
|
|
22291
|
-
function isElectron() {
|
|
22292
|
-
return "type" in process2;
|
|
22293
|
-
}
|
|
22294
22294
|
|
|
22295
22295
|
// src/adapters/mcp.ts
|
|
22296
22296
|
async function callMcpAdapter(config2, input) {
|
package/dist/server/index.js
CHANGED
|
@@ -19807,7 +19807,7 @@ var AssertObjectSchema = custom((v) => v !== null && (typeof v === "object" || t
|
|
|
19807
19807
|
var ProgressTokenSchema = union([string2(), number2().int()]);
|
|
19808
19808
|
var CursorSchema = string2();
|
|
19809
19809
|
var TaskCreationParamsSchema = looseObject({
|
|
19810
|
-
ttl:
|
|
19810
|
+
ttl: number2().optional(),
|
|
19811
19811
|
pollInterval: number2().optional()
|
|
19812
19812
|
});
|
|
19813
19813
|
var TaskMetadataSchema = object2({
|
|
@@ -19961,7 +19961,8 @@ var ClientCapabilitiesSchema = object2({
|
|
|
19961
19961
|
roots: object2({
|
|
19962
19962
|
listChanged: boolean2().optional()
|
|
19963
19963
|
}).optional(),
|
|
19964
|
-
tasks: ClientTasksCapabilitySchema.optional()
|
|
19964
|
+
tasks: ClientTasksCapabilitySchema.optional(),
|
|
19965
|
+
extensions: record(string2(), AssertObjectSchema).optional()
|
|
19965
19966
|
});
|
|
19966
19967
|
var InitializeRequestParamsSchema = BaseRequestParamsSchema.extend({
|
|
19967
19968
|
protocolVersion: string2(),
|
|
@@ -19986,7 +19987,8 @@ var ServerCapabilitiesSchema = object2({
|
|
|
19986
19987
|
tools: object2({
|
|
19987
19988
|
listChanged: boolean2().optional()
|
|
19988
19989
|
}).optional(),
|
|
19989
|
-
tasks: ServerTasksCapabilitySchema.optional()
|
|
19990
|
+
tasks: ServerTasksCapabilitySchema.optional(),
|
|
19991
|
+
extensions: record(string2(), AssertObjectSchema).optional()
|
|
19990
19992
|
});
|
|
19991
19993
|
var InitializeResultSchema = ResultSchema.extend({
|
|
19992
19994
|
protocolVersion: string2(),
|
|
@@ -20101,6 +20103,7 @@ var ResourceSchema = object2({
|
|
|
20101
20103
|
uri: string2(),
|
|
20102
20104
|
description: optional(string2()),
|
|
20103
20105
|
mimeType: optional(string2()),
|
|
20106
|
+
size: optional(number2()),
|
|
20104
20107
|
annotations: AnnotationsSchema.optional(),
|
|
20105
20108
|
_meta: optional(looseObject({}))
|
|
20106
20109
|
});
|
|
@@ -22195,7 +22198,7 @@ class StdioClientTransport {
|
|
|
22195
22198
|
},
|
|
22196
22199
|
stdio: ["pipe", "pipe", this._serverParams.stderr ?? "inherit"],
|
|
22197
22200
|
shell: false,
|
|
22198
|
-
windowsHide: process2.platform === "win32"
|
|
22201
|
+
windowsHide: process2.platform === "win32",
|
|
22199
22202
|
cwd: this._serverParams.cwd
|
|
22200
22203
|
});
|
|
22201
22204
|
this._process.on("error", (error2) => {
|
|
@@ -22287,9 +22290,6 @@ class StdioClientTransport {
|
|
|
22287
22290
|
});
|
|
22288
22291
|
}
|
|
22289
22292
|
}
|
|
22290
|
-
function isElectron() {
|
|
22291
|
-
return "type" in process2;
|
|
22292
|
-
}
|
|
22293
22293
|
|
|
22294
22294
|
// src/adapters/mcp.ts
|
|
22295
22295
|
async function callMcpAdapter(config2, input) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hasna/evals",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "Open source AI evaluation framework — LLM-as-judge + assertion-based evals for any AI app. CLI + MCP server.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -65,8 +65,8 @@
|
|
|
65
65
|
"license": "Apache-2.0",
|
|
66
66
|
"dependencies": {
|
|
67
67
|
"@anthropic-ai/sdk": "^0.39.0",
|
|
68
|
-
"@hasna/cloud": "^0.1.
|
|
69
|
-
"@modelcontextprotocol/sdk": "^1.
|
|
68
|
+
"@hasna/cloud": "^0.1.30",
|
|
69
|
+
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
70
70
|
"ajv": "^8.18.0",
|
|
71
71
|
"chalk": "^5.4.1",
|
|
72
72
|
"commander": "^13.1.0",
|