@hasna/conversations 0.2.19 → 0.2.21
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/bin/index.js +12 -2
- package/bin/mcp.js +12 -2
- package/dist/lib/pg-migrations.d.ts +7 -0
- package/package.json +4 -3
package/bin/index.js
CHANGED
|
@@ -13349,7 +13349,7 @@ var init_poll = __esm(() => {
|
|
|
13349
13349
|
var require_package = __commonJS((exports, module) => {
|
|
13350
13350
|
module.exports = {
|
|
13351
13351
|
name: "@hasna/conversations",
|
|
13352
|
-
version: "0.2.
|
|
13352
|
+
version: "0.2.21",
|
|
13353
13353
|
description: "Real-time CLI messaging for AI agents",
|
|
13354
13354
|
type: "module",
|
|
13355
13355
|
bin: {
|
|
@@ -13378,7 +13378,8 @@ var require_package = __commonJS((exports, module) => {
|
|
|
13378
13378
|
test: "bun test",
|
|
13379
13379
|
dev: "bun run ./src/cli/index.tsx",
|
|
13380
13380
|
typecheck: "tsc --noEmit",
|
|
13381
|
-
prepublishOnly: "bun run build"
|
|
13381
|
+
prepublishOnly: "bun run build",
|
|
13382
|
+
postinstall: "mkdir -p $HOME/.hasna/conversations $HOME/.hasna/conversations/training 2>/dev/null || true"
|
|
13382
13383
|
},
|
|
13383
13384
|
keywords: [
|
|
13384
13385
|
"conversations",
|
|
@@ -43999,6 +44000,15 @@ Last message: ${rows[0]?.created_at?.slice(0, 16) ?? "?"}`);
|
|
|
43999
44000
|
`);
|
|
44000
44001
|
return { content: [{ type: "text", text: result }] };
|
|
44001
44002
|
});
|
|
44003
|
+
server.tool("send_feedback", "Send feedback about this service", { message: exports_external2.string(), email: exports_external2.string().optional(), category: exports_external2.enum(["bug", "feature", "general"]).optional() }, async (params) => {
|
|
44004
|
+
try {
|
|
44005
|
+
const db2 = (await Promise.resolve().then(() => (init_db(), exports_db))).getDb();
|
|
44006
|
+
db2.prepare("INSERT INTO feedback (message, email, category, version) VALUES (?, ?, ?, ?)").run(params.message, params.email || null, params.category || "general", import__package.default.version);
|
|
44007
|
+
return { content: [{ type: "text", text: "Feedback saved. Thank you!" }] };
|
|
44008
|
+
} catch (e) {
|
|
44009
|
+
return { content: [{ type: "text", text: String(e) }], isError: true };
|
|
44010
|
+
}
|
|
44011
|
+
});
|
|
44002
44012
|
isDirectRun = import.meta.url === `file://${process.argv[1]}` || process.argv[1]?.endsWith("mcp.js") || process.argv[1]?.endsWith("mcp.ts");
|
|
44003
44013
|
if (isDirectRun) {
|
|
44004
44014
|
startMcpServer().catch((error48) => {
|
package/bin/mcp.js
CHANGED
|
@@ -39782,7 +39782,7 @@ function getGraphStats() {
|
|
|
39782
39782
|
// package.json
|
|
39783
39783
|
var package_default = {
|
|
39784
39784
|
name: "@hasna/conversations",
|
|
39785
|
-
version: "0.2.
|
|
39785
|
+
version: "0.2.21",
|
|
39786
39786
|
description: "Real-time CLI messaging for AI agents",
|
|
39787
39787
|
type: "module",
|
|
39788
39788
|
bin: {
|
|
@@ -39811,7 +39811,8 @@ var package_default = {
|
|
|
39811
39811
|
test: "bun test",
|
|
39812
39812
|
dev: "bun run ./src/cli/index.tsx",
|
|
39813
39813
|
typecheck: "tsc --noEmit",
|
|
39814
|
-
prepublishOnly: "bun run build"
|
|
39814
|
+
prepublishOnly: "bun run build",
|
|
39815
|
+
postinstall: "mkdir -p $HOME/.hasna/conversations $HOME/.hasna/conversations/training 2>/dev/null || true"
|
|
39815
39816
|
},
|
|
39816
39817
|
keywords: [
|
|
39817
39818
|
"conversations",
|
|
@@ -41371,6 +41372,15 @@ server.registerTool("describe_tools", {
|
|
|
41371
41372
|
`);
|
|
41372
41373
|
return { content: [{ type: "text", text: result }] };
|
|
41373
41374
|
});
|
|
41375
|
+
server.tool("send_feedback", "Send feedback about this service", { message: exports_external.string(), email: exports_external.string().optional(), category: exports_external.enum(["bug", "feature", "general"]).optional() }, async (params) => {
|
|
41376
|
+
try {
|
|
41377
|
+
const db2 = (await Promise.resolve().then(() => (init_db(), exports_db))).getDb();
|
|
41378
|
+
db2.prepare("INSERT INTO feedback (message, email, category, version) VALUES (?, ?, ?, ?)").run(params.message, params.email || null, params.category || "general", package_default.version);
|
|
41379
|
+
return { content: [{ type: "text", text: "Feedback saved. Thank you!" }] };
|
|
41380
|
+
} catch (e) {
|
|
41381
|
+
return { content: [{ type: "text", text: String(e) }], isError: true };
|
|
41382
|
+
}
|
|
41383
|
+
});
|
|
41374
41384
|
async function startMcpServer() {
|
|
41375
41385
|
const transport = new StdioServerTransport;
|
|
41376
41386
|
await server.connect(transport);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* PostgreSQL migrations for open-conversations cloud sync.
|
|
3
|
+
*
|
|
4
|
+
* Equivalent of the SQLite schema in db.ts, translated for PostgreSQL.
|
|
5
|
+
* Each element is a standalone SQL string that must be executed in order.
|
|
6
|
+
*/
|
|
7
|
+
export declare const PG_MIGRATIONS: string[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hasna/conversations",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.21",
|
|
4
4
|
"description": "Real-time CLI messaging for AI agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -29,7 +29,8 @@
|
|
|
29
29
|
"test": "bun test",
|
|
30
30
|
"dev": "bun run ./src/cli/index.tsx",
|
|
31
31
|
"typecheck": "tsc --noEmit",
|
|
32
|
-
"prepublishOnly": "bun run build"
|
|
32
|
+
"prepublishOnly": "bun run build",
|
|
33
|
+
"postinstall": "mkdir -p $HOME/.hasna/conversations $HOME/.hasna/conversations/training 2>/dev/null || true"
|
|
33
34
|
},
|
|
34
35
|
"keywords": [
|
|
35
36
|
"conversations",
|
|
@@ -76,4 +77,4 @@
|
|
|
76
77
|
"url": "https://github.com/hasna/conversations/issues"
|
|
77
78
|
},
|
|
78
79
|
"homepage": "https://github.com/hasna/conversations#readme"
|
|
79
|
-
}
|
|
80
|
+
}
|