@volter/supercode-frontend-vscode 0.1.17 → 0.1.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/README.md +19 -5
- package/dist/extension.js +38 -9
- package/dist/host-controls.d.ts +1 -0
- package/package.json +7 -2
package/README.md
CHANGED
|
@@ -102,11 +102,25 @@ and returns its new scoped connection. The host owns validation, process lifetim
|
|
|
102
102
|
persistence, and failure handling. Prompts and approvals still use the generated frontend client.
|
|
103
103
|
The contract is in `src/host-controls.ts`.
|
|
104
104
|
|
|
105
|
-
With that host, **Chat: New Chat: Choose
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
105
|
+
With that host, **New Session** / **Chat: New Chat: Choose Agent** asks only
|
|
106
|
+
which startable agent to use. It refreshes the host's available choices first;
|
|
107
|
+
with one agent it opens immediately, and with none it returns to setup. Model
|
|
108
|
+
and reasoning are sent as empty values, leaving both at the harness's own defaults,
|
|
109
|
+
even if the previous conversation used explicit settings. Cancelling the agent
|
|
110
|
+
picker creates nothing.
|
|
111
|
+
|
|
112
|
+
The composer's native **Model settings** control offers **Choose model and reasoning
|
|
113
|
+
for a new chat…** for Claude Code and Codex. This optional path retains the model
|
|
114
|
+
list, exact model ID entry and reasoning choices. Only completing the choices
|
|
115
|
+
starts a separate conversation; cancelling either leaves the current one intact.
|
|
116
|
+
A conversation's harness, model and reasoning remain fixed: this integration does
|
|
117
|
+
not advertise hot swapping. The built-in model picker still displays the selected
|
|
118
|
+
model and provider icon; nondelegating session providers cannot add its Manage
|
|
119
|
+
Models action, so configuration uses the native session-options command door.
|
|
120
|
+
The response author identifies the harness. Other harnesses keep their own defaults.
|
|
121
|
+
|
|
122
|
+
This simplified creation flow is source-only pending frontend compilation and a
|
|
123
|
+
live check of zero/one picker, cancellation, defaults and explicit configuration.
|
|
110
124
|
|
|
111
125
|
The host publishes durable conversation IDs and their exact harness history identities.
|
|
112
126
|
`POST /open` resumes only the requested saved conversation; `POST /remember` binds its
|
package/dist/extension.js
CHANGED
|
@@ -451,7 +451,7 @@ export async function activate(context) {
|
|
|
451
451
|
statusIcon: new vscode.ThemeIcon(provider === 'anthropic' ? 'claude' : provider === 'openai' ? 'openai' : provider === 'google' ? 'google-gemini' : 'sparkle'),
|
|
452
452
|
maxInputTokens: 0, maxOutputTokens: 0, capabilities: {},
|
|
453
453
|
targetChatSessionType: SESSION_SCHEME, isUserSelectable: true, isDefault: model.id === selection.model,
|
|
454
|
-
tooltip: `${model.name} via ${harnessDisplayName(selection.harness)}${selection.effort ? ` · ${selection.effort} reasoning` : ''}. Model is fixed for this conversation. Use
|
|
454
|
+
tooltip: `${model.name} via ${harnessDisplayName(selection.harness)}${selection.effort ? ` · ${selection.effort} reasoning` : ''}. Model is fixed for this conversation. Use Model settings to choose model and reasoning for a new conversation.`,
|
|
455
455
|
};
|
|
456
456
|
});
|
|
457
457
|
},
|
|
@@ -671,6 +671,16 @@ export async function activate(context) {
|
|
|
671
671
|
const permissionItems = [{ id: 'ask', name: canApprove ? 'Ask for approval' : 'Harness permissions', description: canApprove ? 'Show each approval requested by the harness.' : 'Approval controls are unavailable for this harness.' },
|
|
672
672
|
...((canApprove || (!active && resource && currentOptions(resource).permissions === 'autoApprove')) ? [{ id: 'autoApprove', name: 'Auto approve', description: 'Allow tool approval requests for this chat. Harness sandbox rules still apply.' }] : [])];
|
|
673
673
|
const groups = [{ id: 'permissions', name: 'Permissions', kind: 'permissions', items: permissionItems, selected: permissionItems.find(i => i.id === (resource ? currentOptions(resource).permissions : 'ask')) }];
|
|
674
|
+
const selected = controls?.state.sessions.find(session => session.id === id);
|
|
675
|
+
if (selected && ['claude-code', 'codex'].includes(selected.selection.harness)) {
|
|
676
|
+
// Native session-option commands remain reachable for nondelegating providers,
|
|
677
|
+
// whose built-in model picker deliberately omits Manage Models. Do not advertise
|
|
678
|
+
// hot swapping: the command opens a separate conversation after both choices.
|
|
679
|
+
// A locked selected item hides the entire native dropdown, including commands.
|
|
680
|
+
const item = { id: 'settings', name: 'Model settings' };
|
|
681
|
+
groups.push({ id: 'modelSettings', name: 'Model', items: [item], selected: item,
|
|
682
|
+
commands: [{ command: 'supercode.frontend.configureModel', title: 'Choose model and reasoning for a new chat…', arguments: [selected.id] }] });
|
|
683
|
+
}
|
|
674
684
|
return groups;
|
|
675
685
|
},
|
|
676
686
|
setPermission: (resource, value) => {
|
|
@@ -685,7 +695,7 @@ export async function activate(context) {
|
|
|
685
695
|
create: async (inputState) => {
|
|
686
696
|
if (!controls)
|
|
687
697
|
throw new Error('The host does not expose conversation creation.');
|
|
688
|
-
await enqueueSelection({
|
|
698
|
+
await enqueueSelection({ harness: controls.state.selection.harness, model: '', effort: '' }, false);
|
|
689
699
|
const connection = frontends.get(controls.state.activeSession);
|
|
690
700
|
savePermission(connection.id, turnPermission(inputState.groups.find(group => group.id === 'permissions')?.selected?.id));
|
|
691
701
|
return connection;
|
|
@@ -737,15 +747,34 @@ export async function activate(context) {
|
|
|
737
747
|
void vscode.window.showInformationMessage('This host does not expose chat configuration.');
|
|
738
748
|
return;
|
|
739
749
|
}
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
750
|
+
await controls.refresh();
|
|
751
|
+
// The host supplies startable agents, including installation/authentication checks.
|
|
752
|
+
// An absent choice is not permission to guess a harness or start another runtime.
|
|
753
|
+
const choices = controls.state.harnesses;
|
|
754
|
+
if (!choices.length) {
|
|
755
|
+
await revealSetup();
|
|
743
756
|
return;
|
|
744
|
-
if (harness.id !== selection.harness) {
|
|
745
|
-
selection.harness = harness.id;
|
|
746
|
-
selection.model = '';
|
|
747
|
-
selection.effort = '';
|
|
748
757
|
}
|
|
758
|
+
const harness = choices.length === 1 ? choices[0] : await vscode.window.showQuickPick(choices.map(h => ({ label: h.name, id: h.id })), { title: 'New chat · Agent', placeHolder: 'Choose your coding agent. Model and reasoning use its defaults.' });
|
|
759
|
+
if (!harness)
|
|
760
|
+
return;
|
|
761
|
+
await enqueueSelection({ harness: harness.id, model: '', effort: '' });
|
|
762
|
+
}));
|
|
763
|
+
context.subscriptions.push(vscode.commands.registerCommand('supercode.frontend.configureModel', async (resource, sessionId) => {
|
|
764
|
+
if (!controls || focusedAttached)
|
|
765
|
+
throw new Error('Model settings require a host-managed conversation.');
|
|
766
|
+
await controls.refresh();
|
|
767
|
+
// The native session-options picker prepends its exact resource to command arguments.
|
|
768
|
+
const bound = resource ? boundId(resource) : undefined;
|
|
769
|
+
if (resource && (!bound || (sessionId && bound !== sessionId)))
|
|
770
|
+
throw new Error('Model settings have no matching conversation binding.');
|
|
771
|
+
const id = bound ?? controls.state.activeSession;
|
|
772
|
+
const selected = controls.state.sessions.find(session => session.id === id);
|
|
773
|
+
if (!selected || selected.id !== controls.state.activeSession)
|
|
774
|
+
throw new Error('Open this conversation before choosing model settings.');
|
|
775
|
+
const selection = { ...selected.selection };
|
|
776
|
+
if (!['claude-code', 'codex'].includes(selection.harness))
|
|
777
|
+
throw new Error('This harness uses its own model defaults; configuration is not advertised.');
|
|
749
778
|
if (['claude-code', 'codex'].includes(selection.harness)) {
|
|
750
779
|
const choices = controls.state.modelsByHarness?.[selection.harness] ?? [{ id: '', name: 'Harness default' }];
|
|
751
780
|
const picked = await vscode.window.showQuickPick([...choices.map(model => ({ label: model.name, id: model.id })), { label: 'Enter an exact model ID…', id: '__custom__' }], { title: 'New chat · Model', placeHolder: 'Model availability depends on your harness account.' });
|
package/dist/host-controls.d.ts
CHANGED
|
@@ -46,6 +46,7 @@ export interface HostState {
|
|
|
46
46
|
sessions: ManagedChatSession[];
|
|
47
47
|
selection: ChatSelection;
|
|
48
48
|
connection?: Record<string, string>;
|
|
49
|
+
/** Agents the host can start now (installation, authentication and capability checked). */
|
|
49
50
|
harnesses: ChatChoice[];
|
|
50
51
|
models: ChatChoice[];
|
|
51
52
|
modelsByHarness?: Record<string, ChatChoice[]>;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@volter/supercode-frontend-vscode",
|
|
3
3
|
"displayName": "Volter Harness",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.18",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "VS Code chat-view frontend for an existing Volter Harness SDK runtime",
|
|
7
7
|
"publisher": "volter-ai-dev",
|
|
@@ -140,9 +140,14 @@
|
|
|
140
140
|
},
|
|
141
141
|
{
|
|
142
142
|
"command": "supercode.frontend.configure",
|
|
143
|
-
"title": "New Chat: Choose
|
|
143
|
+
"title": "New Chat: Choose Agent",
|
|
144
144
|
"category": "Chat",
|
|
145
145
|
"icon": "$(add)"
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
"command": "supercode.frontend.configureModel",
|
|
149
|
+
"title": "Model and Reasoning: Open New Chat",
|
|
150
|
+
"category": "Chat"
|
|
146
151
|
}
|
|
147
152
|
],
|
|
148
153
|
"configuration": {
|