@aexol/opencode-wizard 0.1.2 → 0.1.3
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 +1 -1
- package/dist/server.d.ts +233 -0
- package/dist/server.js +1788 -0
- package/dist/server.js.map +1 -0
- package/dist/smoke-published-skills.d.ts +1 -0
- package/dist/smoke-published-skills.js +84 -0
- package/dist/smoke-published-skills.js.map +1 -0
- package/dist/tui.d.ts +60 -0
- package/dist/tui.js +288 -0
- package/dist/tui.js.map +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -56,7 +56,7 @@ No-arg discovery returns published skill summaries, assignment counts split into
|
|
|
56
56
|
## Release flow
|
|
57
57
|
|
|
58
58
|
1. Bump `version` in `plugin/opencode-wizard/package.json`.
|
|
59
|
-
2. Run `npm run plugin:
|
|
59
|
+
2. Run `npm run plugin:release:check` from the repo root.
|
|
60
60
|
3. If you are following the repo release-tag convention, create Git tag `plugin-opencode-wizard-v<version>`.
|
|
61
61
|
4. Push the release commit/tag so GitLab can run the shared npm public publish job.
|
|
62
62
|
|
package/dist/server.d.ts
ADDED
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
export declare const PLUGIN_ID = "opencode-wizard";
|
|
2
|
+
type ResolvedConfig = {
|
|
3
|
+
backendOrigin: string;
|
|
4
|
+
graphqlUrl: string;
|
|
5
|
+
authSessionUrl: string;
|
|
6
|
+
presenceUrl: string;
|
|
7
|
+
actionsUrl: string;
|
|
8
|
+
fallbackWorkspaceSlug: string;
|
|
9
|
+
rootSkillSeedPath: string;
|
|
10
|
+
authStatePath: string;
|
|
11
|
+
};
|
|
12
|
+
type WorkspaceResolution = {
|
|
13
|
+
requestedDirectory: string;
|
|
14
|
+
repositoryRoot: string;
|
|
15
|
+
repositoryUrl: string | null;
|
|
16
|
+
fallbackWorkspaceSlug: string | null;
|
|
17
|
+
directoryPath: string;
|
|
18
|
+
cacheKey: string;
|
|
19
|
+
};
|
|
20
|
+
export type PublishedSkillCatalogPayload = {
|
|
21
|
+
workspace: {
|
|
22
|
+
id: string;
|
|
23
|
+
slug: string;
|
|
24
|
+
name: string;
|
|
25
|
+
repositoryUrl?: string | null;
|
|
26
|
+
defaultBranch?: string | null;
|
|
27
|
+
status: string;
|
|
28
|
+
};
|
|
29
|
+
directoryPath: string;
|
|
30
|
+
skills: PublishedSkillCatalogItem[];
|
|
31
|
+
};
|
|
32
|
+
export type PublishedSkillCatalogItem = {
|
|
33
|
+
assignmentSource: string;
|
|
34
|
+
assignmentType: string;
|
|
35
|
+
scopePath: string;
|
|
36
|
+
includeChildren?: boolean | null;
|
|
37
|
+
skill: {
|
|
38
|
+
id: string;
|
|
39
|
+
slug: string;
|
|
40
|
+
name: string;
|
|
41
|
+
summary?: string | null;
|
|
42
|
+
whenToUse?: string | null;
|
|
43
|
+
status: string;
|
|
44
|
+
installPolicy: PublishedSkillInstallPolicy;
|
|
45
|
+
tags: PublishedSkillTag[];
|
|
46
|
+
};
|
|
47
|
+
skillVersion: {
|
|
48
|
+
id: string;
|
|
49
|
+
version: string;
|
|
50
|
+
title?: string | null;
|
|
51
|
+
summary?: string | null;
|
|
52
|
+
status: string;
|
|
53
|
+
};
|
|
54
|
+
publishedArtifact: {
|
|
55
|
+
id: string;
|
|
56
|
+
frontmatterName: string;
|
|
57
|
+
frontmatterDescription: string;
|
|
58
|
+
checksum: string;
|
|
59
|
+
publishedAt: string;
|
|
60
|
+
};
|
|
61
|
+
};
|
|
62
|
+
type PublishedSkillFacet = {
|
|
63
|
+
id: string;
|
|
64
|
+
slug: string;
|
|
65
|
+
label: string;
|
|
66
|
+
description?: string | null;
|
|
67
|
+
};
|
|
68
|
+
type PublishedSkillTag = {
|
|
69
|
+
id: string;
|
|
70
|
+
slug: string;
|
|
71
|
+
label: string;
|
|
72
|
+
description?: string | null;
|
|
73
|
+
facet?: PublishedSkillFacet | null;
|
|
74
|
+
};
|
|
75
|
+
type PublishedSkillFacetSummary = {
|
|
76
|
+
slug: string;
|
|
77
|
+
label: string;
|
|
78
|
+
description: string | null;
|
|
79
|
+
};
|
|
80
|
+
type PublishedSkillTagSummary = {
|
|
81
|
+
slug: string;
|
|
82
|
+
label: string;
|
|
83
|
+
description: string | null;
|
|
84
|
+
facet: PublishedSkillFacetSummary | null;
|
|
85
|
+
};
|
|
86
|
+
type PublishedSkillInstallPolicy = 'GLOBAL_CONTEXT' | 'PROJECT_INSTALLABLE';
|
|
87
|
+
export type PublishedSkillDetailItem = PublishedSkillCatalogItem & {
|
|
88
|
+
publishedArtifact: PublishedSkillCatalogItem['publishedArtifact'] & {
|
|
89
|
+
markdownBody: string;
|
|
90
|
+
renderedContent: string;
|
|
91
|
+
};
|
|
92
|
+
};
|
|
93
|
+
type AuthState = {
|
|
94
|
+
pluginId: string;
|
|
95
|
+
sessionToken: string;
|
|
96
|
+
expiresAt: string;
|
|
97
|
+
authenticatedAt: string;
|
|
98
|
+
userId: string;
|
|
99
|
+
email: string;
|
|
100
|
+
};
|
|
101
|
+
type FetchResult = {
|
|
102
|
+
ok: true;
|
|
103
|
+
status: 'ready';
|
|
104
|
+
authMode: 'session';
|
|
105
|
+
payload: PublishedSkillCatalogPayload;
|
|
106
|
+
fetchedAt: string;
|
|
107
|
+
source: 'network' | 'cache';
|
|
108
|
+
} | {
|
|
109
|
+
ok: false;
|
|
110
|
+
status: 'missing_auth' | 'request_failed';
|
|
111
|
+
authMode: 'missing' | 'session';
|
|
112
|
+
message: string;
|
|
113
|
+
fetchedAt: string;
|
|
114
|
+
source: 'network' | 'cache';
|
|
115
|
+
};
|
|
116
|
+
type PublishedSkillSummary = {
|
|
117
|
+
skillSlug: string;
|
|
118
|
+
skillName: string;
|
|
119
|
+
artifactName: string;
|
|
120
|
+
artifactDescription: string;
|
|
121
|
+
whenToUse: string | null;
|
|
122
|
+
version: string;
|
|
123
|
+
assignmentSource: string;
|
|
124
|
+
assignmentType: string;
|
|
125
|
+
scopePath: string;
|
|
126
|
+
includeChildren: boolean | null;
|
|
127
|
+
checksum: string;
|
|
128
|
+
publishedAt: string;
|
|
129
|
+
identifiers: string[];
|
|
130
|
+
tags: PublishedSkillTagSummary[];
|
|
131
|
+
contextKind: 'global' | 'project';
|
|
132
|
+
installPolicy: PublishedSkillInstallPolicy;
|
|
133
|
+
policyLabel: string;
|
|
134
|
+
};
|
|
135
|
+
type PublishedSkillDetail = PublishedSkillSummary & {
|
|
136
|
+
skillId: string;
|
|
137
|
+
skillVersionId: string;
|
|
138
|
+
artifactId: string;
|
|
139
|
+
markdownDocument: string;
|
|
140
|
+
markdownBody: string;
|
|
141
|
+
renderedContent: string;
|
|
142
|
+
};
|
|
143
|
+
type OpencodePluginServerInput = {
|
|
144
|
+
worktree: string;
|
|
145
|
+
directory: string;
|
|
146
|
+
};
|
|
147
|
+
type OpencodePluginSystemTransformOutput = {
|
|
148
|
+
system: string[];
|
|
149
|
+
};
|
|
150
|
+
type OpencodePluginServer = (input: OpencodePluginServerInput) => Promise<{
|
|
151
|
+
tool: Record<string, unknown>;
|
|
152
|
+
'experimental.chat.system.transform': (hookInput: unknown, output: OpencodePluginSystemTransformOutput) => Promise<void>;
|
|
153
|
+
}>;
|
|
154
|
+
type PublishedSkillsSuccessState = {
|
|
155
|
+
pluginId: string;
|
|
156
|
+
runtimeMode: 'tool_fetch_only';
|
|
157
|
+
deliveryModel: 'backend_published_global_project_assignments';
|
|
158
|
+
workspace: PublishedSkillCatalogPayload['workspace'];
|
|
159
|
+
directoryPath: string;
|
|
160
|
+
rootSkillSeedPath: string;
|
|
161
|
+
availableTools: string[];
|
|
162
|
+
publishedSkillCount: number;
|
|
163
|
+
assignmentCounts: {
|
|
164
|
+
global: number;
|
|
165
|
+
project: number;
|
|
166
|
+
other: number;
|
|
167
|
+
};
|
|
168
|
+
facets: PublishedSkillFacetSummary[];
|
|
169
|
+
skills: PublishedSkillSummary[];
|
|
170
|
+
};
|
|
171
|
+
export declare const AVAILABLE_PUBLISHED_SKILL_TOOLS: string[];
|
|
172
|
+
export type NativeSkillsUrlCompatibility = {
|
|
173
|
+
configKey: 'skills.urls';
|
|
174
|
+
deliveryMode: 'public_static_registry';
|
|
175
|
+
wizardPrivateDelivery: 'authenticated_scoped_fetch_tool';
|
|
176
|
+
authSupport: 'none';
|
|
177
|
+
guidance: string;
|
|
178
|
+
};
|
|
179
|
+
export declare const NATIVE_SKILLS_URL_COMPATIBILITY: NativeSkillsUrlCompatibility;
|
|
180
|
+
export type PluginAuthStateSummary = {
|
|
181
|
+
status: 'missing' | 'authenticated';
|
|
182
|
+
email: string | null;
|
|
183
|
+
userId: string | null;
|
|
184
|
+
authenticatedAt: string | null;
|
|
185
|
+
expiresAt: string | null;
|
|
186
|
+
};
|
|
187
|
+
export type PluginStatusSnapshot = {
|
|
188
|
+
pluginId: string;
|
|
189
|
+
runtimeMode: 'tool_fetch_only';
|
|
190
|
+
nativeSkillsUrlCompatibility: NativeSkillsUrlCompatibility;
|
|
191
|
+
backendOrigin: string;
|
|
192
|
+
graphqlUrl: string;
|
|
193
|
+
fallbackWorkspaceSlug: string;
|
|
194
|
+
workspaceResolution: ReturnType<typeof toWorkspaceResolutionOutput>;
|
|
195
|
+
rootSkillSeedPath: string;
|
|
196
|
+
authStatePath: string;
|
|
197
|
+
authState: PluginAuthStateSummary;
|
|
198
|
+
status: FetchResult['status'];
|
|
199
|
+
authMode: FetchResult['authMode'];
|
|
200
|
+
fetchedAt: string;
|
|
201
|
+
source: FetchResult['source'];
|
|
202
|
+
availableTools: typeof AVAILABLE_PUBLISHED_SKILL_TOOLS;
|
|
203
|
+
message: string | null;
|
|
204
|
+
catalog: PublishedSkillsSuccessState | null;
|
|
205
|
+
};
|
|
206
|
+
export declare const resolveConfig: (worktree: string) => Promise<ResolvedConfig>;
|
|
207
|
+
export declare const buildSkillMarkdown: (item: PublishedSkillDetailItem) => string;
|
|
208
|
+
export declare const toPublishedSkillDetail: (item: PublishedSkillDetailItem) => PublishedSkillDetail;
|
|
209
|
+
export declare const toPublishedSkillCatalog: (payload: PublishedSkillCatalogPayload) => PublishedSkillsSuccessState;
|
|
210
|
+
export declare const selectPublishedSkills: <TItem extends PublishedSkillCatalogItem>(payload: Omit<PublishedSkillCatalogPayload, "skills"> & {
|
|
211
|
+
skills: TItem[];
|
|
212
|
+
}, identifiers: string[]) => {
|
|
213
|
+
selectedItems: TItem[];
|
|
214
|
+
missingIdentifiers: string[];
|
|
215
|
+
};
|
|
216
|
+
declare const toWorkspaceResolutionOutput: (resolution: WorkspaceResolution) => {
|
|
217
|
+
requestedDirectory: string;
|
|
218
|
+
repositoryRoot: string;
|
|
219
|
+
repositoryUrl: string | null;
|
|
220
|
+
fallbackWorkspaceSlug: string | null;
|
|
221
|
+
directoryPath: string;
|
|
222
|
+
};
|
|
223
|
+
export declare const toPluginAuthStateSummary: (authState: AuthState | null) => PluginAuthStateSummary;
|
|
224
|
+
export declare const resolvePluginStatusSnapshot: ({ worktree, directory, signal, }: {
|
|
225
|
+
worktree: string;
|
|
226
|
+
directory: string;
|
|
227
|
+
signal: AbortSignal;
|
|
228
|
+
}) => Promise<PluginStatusSnapshot>;
|
|
229
|
+
declare const _default: {
|
|
230
|
+
id: string;
|
|
231
|
+
server: OpencodePluginServer;
|
|
232
|
+
};
|
|
233
|
+
export default _default;
|