@cmdoss/agent-pass-plugin 0.1.2-dev.23.1 → 0.1.2-dev.24.1
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/README.md +5 -1
- package/dist/agentpass.js +1 -1
- package/dist/http.js +2 -2
- package/dist/mcp.js +1 -1
- package/dist/public/http.js +2 -2
- package/dist/public-server.js +1 -1
- package/dist/runtime/setup.js +1 -1
- package/dist/sdk-ui.js +1 -1
- package/dist/server.js +1 -1
- package/dist/shared/constants.js +2 -1
- package/dist/workflows.js +4 -3
- package/npm-shrinkwrap.json +2 -2
- package/package.json +2 -2
- package/public/assets/agent-pass-plugin-client.js +2 -2
- package/public/assets/agent-pass-plugin-sdk.js +1 -1
- package/public/index.html +3 -5
- package/public/styles/base.css +1 -1
- package/skills/agent-pass-plugin-trading/SKILL.md +6 -6
package/README.md
CHANGED
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Senro
|
|
2
|
+
|
|
3
|
+
**Senro, powered by Agent Pass.** Package and CLI: `@cmdoss/agent-pass-plugin`
|
|
4
|
+
(`agent-pass-plugin`); those identifiers, MCP tools and `AGENT_PASS_PLUGIN_*`
|
|
5
|
+
variables keep their names.
|
|
2
6
|
|
|
3
7
|
Local Sui trading strategies for Claude Code and Codex. One local service owns
|
|
4
8
|
execution; the browser and MCP are interfaces to it.
|
package/dist/agentpass.js
CHANGED
|
@@ -190,7 +190,7 @@ export async function getIntegrationStatus(options = {}) {
|
|
|
190
190
|
}
|
|
191
191
|
}
|
|
192
192
|
else {
|
|
193
|
-
status.nextSteps.push("In the Testnet workspace, configure an exact owner-bound plan, request its official Agent Pass review, and sign personally in your wallet.
|
|
193
|
+
status.nextSteps.push("In the Testnet workspace, configure an exact owner-bound plan, request its official Agent Pass review, and sign personally in your wallet. Senro manages its isolated local session; Start remains separate.");
|
|
194
194
|
}
|
|
195
195
|
if (options.probeNetwork)
|
|
196
196
|
status.testnet.probe = await probeTestnetRoute();
|
package/dist/http.js
CHANGED
|
@@ -16,8 +16,8 @@ export function setupInfo(port, mode = "paper") {
|
|
|
16
16
|
? `Install locked dependencies if missing and run npm run build, then run PORT=${port} AGENT_PASS_PLUGIN_MODE=${mode} node scripts/setup.mjs --client codex (or claude) --register --start.`
|
|
17
17
|
: `This package is already compiled; do not run npm ci or build inside it. Run PORT=${port} AGENT_PASS_PLUGIN_MODE=${mode} node "${root}/dist/cli.js" setup --client codex (or claude) --register --start.`;
|
|
18
18
|
return {
|
|
19
|
-
prompt: `Set up Agent Pass
|
|
20
|
-
promptPreview: "Set up
|
|
19
|
+
prompt: `Set up Senro, powered by Agent Pass (package @cmdoss/agent-pass-plugin), from ${root}. Read skills/agent-pass-plugin-trading/SKILL.md. Identify whether this is Codex or Claude Code. ${prepare} Verify agent-pass-plugin MCP tools; if a client restart is required, explain that and continue from saved setup.json. ${mode === "testnet" ? "Call onboard first: it must automatically open the Senro wallet connection page if no fresh browser connection exists. Poll onboarding_status and report onboarding complete only after onboardingComplete is true; browser launch or an old address hint is insufficient. Read testnet_capabilities, then ask me for every missing create_testnet_plan value in one message (wallet owner, direction, decimal amounts, price bound, route, duration and gas caps) and keep my earlier answers. Never invent a price or spending limit, and give every number its unit (input asset, demo USDC per SUI, test SUI). Label each step: proposal, confirmed configuration, wallet authorization, Start. After I confirm the configuration, create one draft, request official Agent Pass authorization, show exact returned rules/warnings and wallet review link, and poll verified chain status. Name yourself (Codex or Claude Code) when telling me to return from the browser. When resuming, read list_plans and pending reviews first; continue the existing plan and reuse the same requestId instead of creating another plan or authorization request. Owner signatures and Start are separate explicit user actions. Mainnet is disabled." : "Guide me through paper account/funding/plan review links. This is simulated trading, not onchain."} Never confirm/sign reviews for me, request a private key, or start a plan without my explicit instruction.`,
|
|
20
|
+
promptPreview: "Set up Senro, connect its MCP, and help me start a strategy.",
|
|
21
21
|
commands: {
|
|
22
22
|
codex: `codex mcp add agent-pass-plugin --env AGENT_PASS_PLUGIN_LOCAL_URL=http://127.0.0.1:${port} -- node ${root}/dist/mcp.js`,
|
|
23
23
|
claude: `claude mcp add --transport stdio --env AGENT_PASS_PLUGIN_LOCAL_URL=http://127.0.0.1:${port} agent-pass-plugin -- node ${root}/dist/mcp.js`,
|
package/dist/mcp.js
CHANGED
|
@@ -80,7 +80,7 @@ const server = new McpServer({ name: SERVICE_ID, version: "0.1.0" }, {
|
|
|
80
80
|
let onboardingRequestId = randomUUID();
|
|
81
81
|
let onboardingId;
|
|
82
82
|
server.registerTool("onboard", {
|
|
83
|
-
description: "Complete Testnet wallet onboarding. Automatically open the local
|
|
83
|
+
description: "Complete Testnet wallet onboarding. Automatically open the local Senro connection page if a fresh connected browser wallet is missing; return pending until the user actually connects. Call this during setup rather than merely telling the user to open a URL. Repeated calls reuse this client session; retryBrowser explicitly retries a failed/dismissed launch. No wallet selection, signature, Pass authorization or trading is performed.",
|
|
84
84
|
inputSchema: { retryBrowser: z.boolean().optional() },
|
|
85
85
|
outputSchema: QuoteDataSchema,
|
|
86
86
|
annotations: mutate,
|
package/dist/public/http.js
CHANGED
|
@@ -23,8 +23,8 @@ function publicReleaseIdentity(env) {
|
|
|
23
23
|
}
|
|
24
24
|
export function publicSetup() {
|
|
25
25
|
return {
|
|
26
|
-
prompt: `Set up Agent Pass
|
|
27
|
-
promptPreview: "Set up
|
|
26
|
+
prompt: `Set up Senro, powered by Agent Pass, locally from the public npm package @cmdoss/agent-pass-plugin@${packageMetadata().version}. Use Node 22.13+ and npm. Identify whether this is Claude Code or Codex and run PORT=4317 AGENT_PASS_PLUGIN_MODE=testnet npx --yes @cmdoss/agent-pass-plugin@${packageMetadata().version} setup --client claude (or codex) --register --start. Read the installed README.md and trading skill at skillPath in the setup output. Do not clone the private GitHub repository or build inside the installed package. Verify the agent-pass-plugin MCP tools, then marketplace_status and onboard; poll onboarding_status until the wallet is actually connected. Keep all keys, signing, plan data and the runner on my machine. Use Sui Testnet demo assets. Help me choose a strategy and collect its explicit amounts, price, budget, duration and gas limits. Owner authorization and Start are separate user actions. Do not authorize, sign or Start on my behalf, and never request a private key.`,
|
|
27
|
+
promptPreview: "Set up Senro on your machine and connect its MCP.",
|
|
28
28
|
};
|
|
29
29
|
}
|
|
30
30
|
/** Hosted catalog only. This module never opens a store, signer or runner. */
|
package/dist/public-server.js
CHANGED
|
@@ -8,4 +8,4 @@ for (const signal of ["SIGINT", "SIGTERM"])
|
|
|
8
8
|
void app.close();
|
|
9
9
|
});
|
|
10
10
|
await app.listen({ host: "0.0.0.0", port });
|
|
11
|
-
console.log(`
|
|
11
|
+
console.log(`Senro public catalog listening on port ${port}. Trading remains local.`);
|
package/dist/runtime/setup.js
CHANGED
|
@@ -53,7 +53,7 @@ export async function setup(args) {
|
|
|
53
53
|
value.apiVersion !== 1)
|
|
54
54
|
return false;
|
|
55
55
|
if (value.workspaceId !== workspaceId)
|
|
56
|
-
throw new Error("This port belongs to a different
|
|
56
|
+
throw new Error("This port belongs to a different Senro workspace. Choose another PORT or connect to the intended data directory.");
|
|
57
57
|
if (value.mode !== mode)
|
|
58
58
|
throw new Error(`This runtime uses ${value.mode}; expected ${mode}. Restart it explicitly in the intended mode.`);
|
|
59
59
|
if (value.runtimeVersion !== version || value.runtimeBuildId !== buildId)
|
package/dist/sdk-ui.js
CHANGED
|
@@ -23,7 +23,7 @@ export async function buildSdkUi() {
|
|
|
23
23
|
let html = await readFile(join(sdk, "web-dist/index.html"), "utf8");
|
|
24
24
|
html = html
|
|
25
25
|
.replace(/<link rel="icon"[^>]*>/, "")
|
|
26
|
-
.replace("<title>Sui Agent Pass · Your money. Your rules.</title>", "<title>
|
|
26
|
+
.replace("<title>Sui Agent Pass · Your money. Your rules.</title>", "<title>Senro · Agent Pass</title>")
|
|
27
27
|
.replace("</head>", `<link rel="stylesheet" href="/plugin/styles/tokens.css"><link rel="stylesheet" href="/plugin/styles.css"><link rel="stylesheet" href="/plugin/styles/sdk.css"><script type="module" src="/assets/agent-pass-plugin-sdk.js"></script></head>`);
|
|
28
28
|
return reply.type("text/html").send(html);
|
|
29
29
|
});
|
package/dist/server.js
CHANGED
|
@@ -90,7 +90,7 @@ try {
|
|
|
90
90
|
console.error("Runner cycle failed; pending intents will reconcile before further work.", e.message);
|
|
91
91
|
}
|
|
92
92
|
}, LOOP_INTERVAL_MS);
|
|
93
|
-
console.log(`
|
|
93
|
+
console.log(`Senro local workspace: http://127.0.0.1:${port}`);
|
|
94
94
|
console.log(mode === "testnet"
|
|
95
95
|
? "Mode: SUI TESTNET. Owner wallet authorization and explicit Start are required. Demo assets only; mainnet is disabled."
|
|
96
96
|
: "Mode: PAPER. All balances, approvals, fills and prices are simulated. No private keys needed.");
|
package/dist/shared/constants.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
/** Product and local transport defaults shared by server and browser bundles. */
|
|
2
|
-
|
|
2
|
+
/** Display name only (TRE-11). Package, CLI, MCP, env and skill identifiers keep agent-pass-plugin. */
|
|
3
|
+
export const PRODUCT_NAME = "Senro";
|
|
3
4
|
export const SERVICE_ID = "agent-pass-plugin";
|
|
4
5
|
export const DEFAULT_APP_PORT = 4317;
|
|
5
6
|
export const SDK_UI_PORT = 58529;
|
package/dist/workflows.js
CHANGED
|
@@ -3,6 +3,7 @@ import { chmodSync, mkdirSync, renameSync, unlinkSync, writeFileSync, } from "no
|
|
|
3
3
|
import { dirname } from "node:path";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
import { fingerprint, hash, MICRO, micros, NANO, catalog as strategies, } from "./domain.js";
|
|
6
|
+
import { PRODUCT_NAME } from "./shared/constants.js";
|
|
6
7
|
export const REVIEW_TTL_MS = 15 * 60 * 1000;
|
|
7
8
|
const uuid = z.string().uuid();
|
|
8
9
|
const fundingAmount = z
|
|
@@ -330,12 +331,12 @@ export class Workflows {
|
|
|
330
331
|
catalog(query) {
|
|
331
332
|
const value = (query ?? "").trim().toLowerCase();
|
|
332
333
|
return strategies
|
|
333
|
-
.filter((bot) => `${bot.name} ${bot.description}
|
|
334
|
+
.filter((bot) => `${bot.name} ${bot.description} ${PRODUCT_NAME}`
|
|
334
335
|
.toLowerCase()
|
|
335
336
|
.includes(value))
|
|
336
337
|
.map((bot) => ({
|
|
337
338
|
...bot,
|
|
338
|
-
author:
|
|
339
|
+
author: PRODUCT_NAME,
|
|
339
340
|
mode: "paper",
|
|
340
341
|
performance: this.performance(bot.id),
|
|
341
342
|
}));
|
|
@@ -344,7 +345,7 @@ export class Workflows {
|
|
|
344
345
|
const strategy = this.catalog().find((bot) => bot.id === id);
|
|
345
346
|
if (!strategy)
|
|
346
347
|
throw new Error("Strategy not found.");
|
|
347
|
-
const skillMarkdown = `# ${strategy.name}\n\nAuthor:
|
|
348
|
+
const skillMarkdown = `# ${strategy.name}\n\nAuthor: ${PRODUCT_NAME}\nVersion: ${strategy.version}\nMode: PAPER\n\n## Rules\n\n${strategy.description}\n\n## Parameters\n\nUSDC per buy, total budget, UTC daily spending limit, interval, expiry, and (for Price Watch) the SUI/USDC target price.\n\n## Controls and execution\n\nCreate a draft through MCP, request authorization, and review its exact fingerprint on the web. Confirmation does not start execution. Start separately through MCP; the independent local runner stays active while its process is running. Pause/resume keeps the original order cadence. Stop and paper revoke leave existing holdings untouched.\n\n## Simulation boundary\n\nPaper USDC/SUI balances, manual prices, a 30 bps trading fee, no market impact, no modeled slippage, and no on-chain transactions. Slippage settings are reserved for the live adapter and do not affect paper fills. PnL is marked from actual local paper fills at the current simulated price; it is not real profit or a verified 30-day record.\n`;
|
|
348
349
|
return { ...strategy, rules: strategy.description, skillMarkdown };
|
|
349
350
|
}
|
|
350
351
|
plansSummary() {
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cmdoss/agent-pass-plugin",
|
|
3
|
-
"version": "0.1.2-dev.
|
|
3
|
+
"version": "0.1.2-dev.24.1",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@cmdoss/agent-pass-plugin",
|
|
9
|
-
"version": "0.1.2-dev.
|
|
9
|
+
"version": "0.1.2-dev.24.1",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@fastify/static": "10.1.10",
|
|
12
12
|
"@modelcontextprotocol/sdk": "1.32.2",
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cmdoss/agent-pass-plugin",
|
|
3
|
-
"version": "0.1.2-dev.
|
|
3
|
+
"version": "0.1.2-dev.24.1",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"description": "Agent Pass
|
|
5
|
+
"description": "Senro, powered by Agent Pass — local trading strategies, explicit permissions and an independent execution loop",
|
|
6
6
|
"engines": {
|
|
7
7
|
"node": ">=22.13.0"
|
|
8
8
|
},
|