@quspect/qupai 0.7.7 → 0.7.12
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/SKILL.md +7 -6
- package/bin/qupai.js +3 -1
- package/package.json +7 -7
- package/tui/qupai-tui.mjs +63 -60
package/SKILL.md
CHANGED
|
@@ -6,9 +6,9 @@ description: Ask QuPai's agents (the agents of the products the person's organiz
|
|
|
6
6
|
# Using QuPai through the qupai command
|
|
7
7
|
|
|
8
8
|
`qupai` asks QuPai's agents for the person. Each ask is a thread of theirs in the QuPai app and an ordinary billed
|
|
9
|
-
turn in their account. A change on a real machine (a lab instrument, a quantum computer) always waits for the person
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
turn in their account. A change on a real machine (a lab instrument, a quantum computer) always waits for the person's
|
|
10
|
+
approval: you never approve anything and have no access to a lab's own tools (you ask the lab's agent). As an MCP
|
|
11
|
+
server (below) qupai asks the person in your client's own dialog; from your shell you hand them the link.
|
|
12
12
|
|
|
13
13
|
## 1. Check the sign-in
|
|
14
14
|
|
|
@@ -62,7 +62,8 @@ app on their terminal: do not run them.
|
|
|
62
62
|
## 5. When it waits (exit 4)
|
|
63
63
|
|
|
64
64
|
If `status` is `waiting`, give the person `approval_url` (the thread in the QuPai app) and say what the agent wants to
|
|
65
|
-
do. Once they have answered, or if
|
|
65
|
+
do (`note` says why they were not asked where you work); never answer it yourself. Once they have answered, or if
|
|
66
|
+
`status` was `running`:
|
|
66
67
|
|
|
67
68
|
```sh
|
|
68
69
|
qupai wait -thread <thread> -json -timeout 90s
|
|
@@ -128,7 +129,7 @@ qupai admin lab grant csmot -org acme -user bob@acme.example -role operate
|
|
|
128
129
|
`claude mcp add qupai -- qupai mcp` (Codex: `codex mcp add qupai -- qupai mcp`) offers the same as tools: `status`,
|
|
129
130
|
`list_agents`, `ask` and `wait`. `ask` takes `prompt` and `product` (with `agent`), `lab` or `thread`; `ask` and `wait`
|
|
130
131
|
follow the turn for at most `timeout_seconds` (default 120, at most 600) and return the same `status`, `answer`,
|
|
131
|
-
`approval_url`, `thread` and `turn
|
|
132
|
-
pass.
|
|
132
|
+
`approval_url`, `thread` and `turn`, plus `answered` when the person answered an approval in your client's dialog
|
|
133
|
+
(MCP elicitation; you never see or answer it). They use the person's sign-in, never a key you pass.
|
|
133
134
|
|
|
134
135
|
This guide is `qupai guide`; `qupai skill install` writes it where Claude Code and Codex read skills.
|
package/bin/qupai.js
CHANGED
|
@@ -7,6 +7,8 @@
|
|
|
7
7
|
// It also tells the binary where the full-screen app is (this package's tui/qupai-tui.mjs) and which Node.js runs it
|
|
8
8
|
// (the one running this file), so `qupai` alone on a terminal opens it: QUPAI_TUI_ENTRY, QUPAI_TUI_NODE and
|
|
9
9
|
// QUPAI_TUI_NODE_VERSION, none of them secret. The binary checks the version (pi-tui needs Node.js 22.19 or later).
|
|
10
|
+
// QUPAI_NPM_ROOT is this package's folder: `qupai update` installs the newest version over it, with the npm beside
|
|
11
|
+
// this Node.js, when it is npm's global install.
|
|
10
12
|
const { spawnSync } = require("node:child_process");
|
|
11
13
|
const { existsSync } = require("node:fs");
|
|
12
14
|
const path = require("node:path");
|
|
@@ -23,7 +25,7 @@ try {
|
|
|
23
25
|
process.exit(1);
|
|
24
26
|
}
|
|
25
27
|
|
|
26
|
-
const env = { ...process.env };
|
|
28
|
+
const env = { ...process.env, QUPAI_NPM_ROOT: path.join(__dirname, "..") };
|
|
27
29
|
const tui = path.join(__dirname, "..", "tui", "qupai-tui.mjs");
|
|
28
30
|
if (existsSync(tui)) {
|
|
29
31
|
env.QUPAI_TUI_ENTRY = tui;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quspect/qupai",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.12",
|
|
4
4
|
"description": "QuPai's command line: sign in to a QuPai platform and ask its agents from a terminal, or from Codex and Claude Code",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": "Quspect",
|
|
@@ -29,11 +29,11 @@
|
|
|
29
29
|
"node": ">=18"
|
|
30
30
|
},
|
|
31
31
|
"optionalDependencies": {
|
|
32
|
-
"@quspect/qupai-darwin-arm64": "0.7.
|
|
33
|
-
"@quspect/qupai-darwin-x64": "0.7.
|
|
34
|
-
"@quspect/qupai-linux-x64": "0.7.
|
|
35
|
-
"@quspect/qupai-linux-arm64": "0.7.
|
|
36
|
-
"@quspect/qupai-win32-x64": "0.7.
|
|
37
|
-
"@quspect/qupai-win32-arm64": "0.7.
|
|
32
|
+
"@quspect/qupai-darwin-arm64": "0.7.12",
|
|
33
|
+
"@quspect/qupai-darwin-x64": "0.7.12",
|
|
34
|
+
"@quspect/qupai-linux-x64": "0.7.12",
|
|
35
|
+
"@quspect/qupai-linux-arm64": "0.7.12",
|
|
36
|
+
"@quspect/qupai-win32-x64": "0.7.12",
|
|
37
|
+
"@quspect/qupai-win32-arm64": "0.7.12"
|
|
38
38
|
}
|
|
39
39
|
}
|