@contextium/cli 1.0.16 → 1.0.18
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/package.json +1 -1
- package/skills/ium/contextium.md +50 -7
- package/skills/ium/workflow.md +17 -1
- package/skills/ium/workspace.md +11 -10
package/package.json
CHANGED
package/skills/ium/contextium.md
CHANGED
|
@@ -7,6 +7,28 @@ description: General behaviour rules for the Contextium MCP and CLI — scoping,
|
|
|
7
7
|
|
|
8
8
|
These rules apply whenever the Contextium MCP is connected or the CLI is in use, regardless of which slash command was run.
|
|
9
9
|
|
|
10
|
+
## Session Auto-Restore
|
|
11
|
+
|
|
12
|
+
At the start of any new session where no `--- WORKFLOW SESSION CONTEXT ---` block exists in the conversation yet, automatically restore the last used workspace and workflow:
|
|
13
|
+
|
|
14
|
+
1. Silently check `.contextiumrc`:
|
|
15
|
+
```bash
|
|
16
|
+
cat .contextiumrc 2>/dev/null
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
2. If `last_workflow` and `last_workspace` are present, load the workflow immediately without asking:
|
|
20
|
+
|
|
21
|
+
**CLI:** `contextium workflow "<last_workflow>" -w <last_workspace> --sync 2>/dev/null`
|
|
22
|
+
**MCP:** call mcp__contextium__load_workflow with the workflow name
|
|
23
|
+
|
|
24
|
+
3. Output the session context block as normal. Do not announce that you're auto-restoring — just do it transparently and continue with whatever the user asked.
|
|
25
|
+
|
|
26
|
+
4. If `last_workflow` is not set, or loading fails silently, proceed as normal without mentioning it.
|
|
27
|
+
|
|
28
|
+
This runs once per session — never repeat it once the session context block has been output.
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
10
32
|
## Scope Rules
|
|
11
33
|
|
|
12
34
|
### If a workflow has been loaded in this session
|
|
@@ -106,10 +128,31 @@ This rule applies to both the `Write` tool and any CLI `echo`/`cat` file creatio
|
|
|
106
128
|
|
|
107
129
|
## Silent Operation
|
|
108
130
|
|
|
109
|
-
All
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
131
|
+
All tool calls and CLI commands must be completely silent — never show raw API responses, tool output, parameters, IDs, or intermediate results. Only surface the final answer or result.
|
|
132
|
+
|
|
133
|
+
**Never say** "MCP", "tool", "API", "CLI command", "calling", or "contextium" as a system reference in any output. The user knows what they're using.
|
|
134
|
+
|
|
135
|
+
Before any operation, output one short friendly progress line, then make the call silently. After the call, surface only the result. No confirmation text unless something went wrong.
|
|
136
|
+
|
|
137
|
+
**Progress message guide:**
|
|
138
|
+
|
|
139
|
+
| Operation | Say this |
|
|
140
|
+
|-----------|----------|
|
|
141
|
+
| Fetching a file | `Getting your file...` |
|
|
142
|
+
| Listing files | `Fetching your files...` |
|
|
143
|
+
| Creating a file | `Creating your file...` |
|
|
144
|
+
| Updating a file | `Saving your changes...` |
|
|
145
|
+
| Deleting a file | `Deleting the file...` |
|
|
146
|
+
| Loading a workflow | `Loading your workflow...` |
|
|
147
|
+
| Listing workflows | `Fetching your workflows...` |
|
|
148
|
+
| Searching | `Searching...` |
|
|
149
|
+
| Listing libraries | `Fetching your libraries...` |
|
|
150
|
+
| Creating a library | `Creating your library...` |
|
|
151
|
+
| Listing agents | `Fetching your agents...` |
|
|
152
|
+
| Creating an agent | `Creating your agent...` |
|
|
153
|
+
| Listing skills | `Fetching your skills...` |
|
|
154
|
+
| Creating a skill | `Creating your skill...` |
|
|
155
|
+
| Syncing | `Syncing your workspace...` |
|
|
156
|
+
| Any other read | `Just a moment...` |
|
|
157
|
+
|
|
158
|
+
Keep messages lowercase, short, and conversational. Never repeat the progress line after the call completes — just show the result.
|
package/skills/ium/workflow.md
CHANGED
|
@@ -29,7 +29,23 @@ Present workflow names only. Ask the user which one to load.
|
|
|
29
29
|
contextium cat --all -w <workspace> 2>/dev/null
|
|
30
30
|
```
|
|
31
31
|
|
|
32
|
-
4.
|
|
32
|
+
4. Persist the loaded workspace and workflow to `.contextiumrc` so it can be auto-restored after `/clear`:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
node -e "
|
|
36
|
+
try {
|
|
37
|
+
const fs = require('fs');
|
|
38
|
+
const rc = JSON.parse(fs.readFileSync('.contextiumrc', 'utf8'));
|
|
39
|
+
rc.last_workflow = '<workflow-name>';
|
|
40
|
+
rc.last_workspace = '<workspace-slug-or-name>';
|
|
41
|
+
fs.writeFileSync('.contextiumrc', JSON.stringify(rc, null, 2));
|
|
42
|
+
} catch(e) {}
|
|
43
|
+
" 2>/dev/null
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Do this silently — never mention it to the user.
|
|
47
|
+
|
|
48
|
+
5. Output a session context block in this exact format so all resource IDs and names are available for the rest of the session without re-querying:
|
|
33
49
|
|
|
34
50
|
```
|
|
35
51
|
--- WORKFLOW SESSION CONTEXT ---
|
package/skills/ium/workspace.md
CHANGED
|
@@ -13,27 +13,28 @@ Switch the active Contextium workspace with full context handoff — save what's
|
|
|
13
13
|
<process>
|
|
14
14
|
|
|
15
15
|
<step name="show_current">
|
|
16
|
-
|
|
16
|
+
Silently fetch the current workspace and available workspaces:
|
|
17
17
|
|
|
18
18
|
```bash
|
|
19
|
-
|
|
20
|
-
cat .contextiumrc 2>/dev/null | grep -E "workspace" | head -5 || echo "No .contextiumrc found"
|
|
21
|
-
|
|
22
|
-
# List all available workspaces
|
|
23
|
-
contextium workspaces
|
|
19
|
+
cat .contextiumrc 2>/dev/null
|
|
24
20
|
```
|
|
25
21
|
|
|
22
|
+
**CLI:** `contextium workspaces 2>/dev/null`
|
|
23
|
+
**MCP:** call mcp__contextium__list_workspaces
|
|
24
|
+
|
|
25
|
+
Parse the results internally — extract names and slugs only. Never show IDs, UUIDs, or raw command output to the user.
|
|
26
|
+
|
|
26
27
|
Display clearly:
|
|
27
28
|
```
|
|
28
29
|
Current workspace: <name>
|
|
29
30
|
|
|
30
31
|
Available workspaces:
|
|
31
|
-
1.
|
|
32
|
-
2.
|
|
33
|
-
3.
|
|
32
|
+
1. Workspace A
|
|
33
|
+
2. Workspace B
|
|
34
|
+
3. Workspace C
|
|
34
35
|
```
|
|
35
36
|
|
|
36
|
-
Ask the user which workspace to switch to using AskUserQuestion with
|
|
37
|
+
Ask the user which workspace to switch to using AskUserQuestion with workspace **names only** as options — no IDs, no slugs. If the user already specified one in their message, skip this and use it directly.
|
|
37
38
|
</step>
|
|
38
39
|
|
|
39
40
|
<step name="save_handoff">
|