-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathpackage.json
More file actions
267 lines (267 loc) · 8.4 KB
/
package.json
File metadata and controls
267 lines (267 loc) · 8.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
{
"name": "kappa",
"displayName": "Kappa",
"description": "General helper for decompilation",
"version": "1.7.0",
"publisher": "macabeus",
"icon": "media/branding/logo.png",
"type": "module",
"workspaces": [
"kappa",
"webview-decomp-permuter"
],
"repository": {
"type": "git",
"url": "https://github.com/macabeus/kappa.git"
},
"engines": {
"vscode": "^1.96.0"
},
"categories": [
"Other"
],
"activationEvents": [
"onLanguage:c",
"onLanguage:cpp"
],
"main": "./dist/extension.cjs",
"contributes": {
"languages": [
{
"id": "cpp",
"filenamePatterns": [
"**/include/c++/**",
"**/MSVC/*/include/**"
],
"firstLine": "^/[/*].*-\\*-\\s*C\\+\\+\\s*-\\*-.*"
},
{
"id": "arm",
"aliases": [
"ARM Assembly",
"arm"
],
"extensions": [
".s",
".S",
".asm"
],
"configuration": "./language-configuration.json"
}
],
"commands": [
{
"command": "kappa.runKappaPlugins",
"title": "Kappa: Run Kappa Plugins"
},
{
"command": "kappa.runTestsForCurrentKappaPlugin",
"title": "Kappa: Run tests for the current Kappa Plugin"
},
{
"command": "kappa.compareSymbolFromObjectFiles",
"title": "Kappa: Compare a symbol from two object files"
},
{
"command": "kappa.runPromptBuilder",
"title": "Kappa: Build a prompt to decompile it"
},
{
"command": "kappa.startDecompilerAgent",
"title": "Kappa: Start the decompiler agent to decompile a function"
},
{
"command": "kappa.indexCodebase",
"title": "Kappa: Index codebase"
},
{
"command": "kappa.reloadDatabase",
"title": "Kappa: Reload database"
},
{
"command": "kappa.showChart",
"title": "Kappa: Show chart"
},
{
"command": "kappa.runDecompYamlCreation",
"title": "Kappa: Create or update decomp.yaml"
},
{
"command": "kappa.changeVoyageApiKey",
"title": "Kappa: Set Voyage AI API Key"
},
{
"command": "kappa.changeM2cPath",
"title": "Kappa: Set M2C Path"
}
],
"configuration": {
"type": "object",
"title": "Kappa",
"properties": {
"kappa.voyageApiKey": {
"type": "string",
"default": "",
"description": "API key for Voyage AI service used for semantic embeddings and search",
"scope": "application"
},
"kappa.m2cPath": {
"type": "string",
"default": "",
"description": "Path for m2c on your computer",
"scope": "machine"
},
"kappa.m2cPythonExecutablePath": {
"type": "string",
"default": "",
"description": "Python executable path to when calling m2c",
"scope": "machine"
},
"kappa.decompPermuterPath": {
"type": "string",
"default": "",
"description": "Path for decomp-permuter on your computer",
"scope": "machine"
},
"kappa.decompPermuterPythonExecutablePath": {
"type": "string",
"default": "",
"description": "Python executable path to when calling permuter",
"scope": "machine"
},
"kappa.askIndexCodebase": {
"type": "boolean",
"default": "true",
"description": "Show the message asking to index the codebase"
}
}
},
"walkthroughs": [
{
"id": "setup",
"title": "Kappa Setup",
"description": "Setup Kappa to work with your codebase.",
"steps": [
{
"id": "setVoyageApiKey",
"title": "Set Voyage AI API Key",
"description": "Optional, but strongly recommended.\n\n[Set API Key](command:kappa.changeVoyageApiKey)",
"media": {
"markdown": "media/walkthroughs/set-voyage-api-key.md"
},
"completionEvents": [
"onContext:walkthroughVoyageApiKeySet"
]
},
{
"id": "indexCodebase",
"title": "Index the codebase",
"description": "[Index the codebase](command:kappa.indexCodebase)",
"media": {
"markdown": "media/walkthroughs/index-codebase.md"
},
"completionEvents": [
"onCommand:kappa.indexCodebase"
]
},
{
"id": "waitForIndexing",
"title": "Wait for the codebase to be indexed",
"media": {
"markdown": "media/walkthroughs/wait-for-indexing.md"
},
"completionEvents": [
"onContext:walkthroughIndexingComplete"
]
}
]
}
],
"languageModelTools": [
{
"name": "get_diff_between_object_files",
"displayName": "Objdiff",
"userDescription": "This tool uses Objdiff to compare two object files and shows their differences.",
"modelDescription": "This tool compares two object files and returns the differences between them. It can be used to understand changes in compiled code, such as function additions, removals, or modifications. You should use this tool whenever you compile the project and you need to analyze the differences between the target assembly and the one from your current C code. You need to specify which function to compare using the `functionName` parameter.",
"canBeReferencedInPrompt": true,
"toolReferenceName": "objdiff",
"icon": "media/branding/logo.png",
"inputSchema": {
"type": "object",
"required": [
"functionName",
"currentObjectFilePath",
"targetObjectFilePath"
],
"properties": {
"functionName": {
"type": "string",
"description": "The name of the function to compare (e.g., 'sub_805ECC4', 'my_function')"
},
"currentObjectFilePath": {
"type": "string",
"description": "The path to the current object file, which is compiled from the source code (e.g., 'build/main.o')"
},
"targetObjectFilePath": {
"type": "string",
"description": "The path to the target object file, which is the one you want to compare against (e.g., 'expected/main.o')"
}
}
}
}
]
},
"vsce": {
"useYarn": false
},
"scripts": {
"build": "node esbuild.js && yarn workspace webview-decomp-permuter build",
"package": "yarn run check-types && yarn run lint && yarn run format:check && node esbuild.js --production && yarn workspace webview-decomp-permuter build",
"build:webview": "yarn workspace webview-decomp-permuter build",
"check-types": "tsc --noEmit",
"lint": "eslint src",
"format": "prettier --write .",
"format:check": "prettier --check .",
"pretest": "yarn build",
"tests:unit": "vitest run",
"tests:unit:watch": "vitest",
"tests:e2e": "wdio run ./src/tests-e2e/wdio.conf.ts"
},
"packageManager": "yarn@4.9.2+sha512.1fc009bc09d13cfd0e19efa44cbfc2b9cf6ca61482725eb35bbc5e257e093ebf4130db6dfe15d604ff4b79efd8e1e8e99b25fa7d0a6197c9f9826358d4d65c3c",
"types": "src/webview-api.ts",
"dependencies": {
"@ast-grep/lang-c": "^0.0.3",
"@ast-grep/napi": "^0.39.3",
"dedent": "^1.6.0",
"diff": "^8.0.2",
"glob": "^11.0.3",
"objdiff-wasm": "^3.0.0",
"rxdb": "^16.15.0",
"rxjs": "^7.8.2",
"umap-js": "^1.4.0",
"vscode-languageclient": "^9.0.1",
"yaml": "^2.8.0",
"zod": "^4.0.5"
},
"devDependencies": {
"@trivago/prettier-plugin-sort-imports": "^5.2.2",
"@types/node": "20.x",
"@types/vscode": "^1.96.0",
"@typescript-eslint/eslint-plugin": "^8.40.0",
"@typescript-eslint/parser": "^8.40.0",
"@wdio/cli": "^9.24.0",
"@wdio/globals": "^9.23.0",
"@wdio/local-runner": "^9.24.0",
"@wdio/mocha-framework": "^9.24.0",
"@wdio/spec-reporter": "^9.24.0",
"esbuild": "^0.25.9",
"eslint": "^9.34.0",
"eslint-plugin-unused-imports": "^4.2.0",
"npm-run-all": "^4.1.5",
"prettier": "^3.6.2",
"typescript": "^5.9.2",
"vitest": "^4.0.16",
"wdio-vscode-service": "^6.1.4",
"webview-decomp-permuter": "workspace:*"
}
}