-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpackage.json
More file actions
134 lines (134 loc) · 4.33 KB
/
Copy pathpackage.json
File metadata and controls
134 lines (134 loc) · 4.33 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
{
"name": "ai-code-commenter",
"displayName": "AI Code Commenter",
"description": "Generates meaningful, professional code comments using Gemini (or other AI providers) without duplicating or cluttering existing documentation.",
"version": "0.2.1",
"publisher": "your-publisher-id",
"private": true,
"engines": {
"vscode": "^1.85.0"
},
"categories": [
"Programming Languages",
"Machine Learning",
"Formatters"
],
"main": "./dist/extension.js",
"contributes": {
"commands": [
{
"command": "aiCodeCommenter.generateComments",
"title": "AI Code Commenter: Generate AI Comments"
},
{
"command": "aiCodeCommenter.setApiKey",
"title": "AI Code Commenter: Set Gemini API Key"
},
{
"command": "aiCodeCommenter.clearApiKey",
"title": "AI Code Commenter: Clear Gemini API Key"
}
],
"menus": {
"editor/context": [
{
"command": "aiCodeCommenter.generateComments",
"when": "editorHasSelection && !editorReadonly",
"group": "1_modification"
}
]
},
"keybindings": [
{
"command": "aiCodeCommenter.generateComments",
"key": "ctrl+alt+c",
"mac": "cmd+alt+c",
"when": "editorTextFocus && editorHasSelection"
}
],
"configuration": {
"title": "AI Code Commenter",
"properties": {
"aiCodeCommenter.provider": {
"type": "string",
"enum": [
"gemini",
"ollama"
],
"enumDescriptions": [
"Google's Gemini API (cloud, requires an API key).",
"A locally-running Ollama server (free, no API key, requires Ollama installed)."
],
"default": "gemini",
"description": "The AI provider used to generate comments."
},
"aiCodeCommenter.model": {
"type": "string",
"default": "gemini-3.5-flash",
"description": "The model name to request from the selected provider (e.g. \"gemini-3.5-flash\" for Gemini, \"llama3.1\" or \"qwen2.5-coder\" for Ollama — must already be pulled via \"ollama pull\"). If unset, a sensible default is chosen per-provider."
},
"aiCodeCommenter.ollamaBaseUrl": {
"type": "string",
"default": "http://localhost:11434",
"description": "Base URL of the local Ollama server, only used when \"aiCodeCommenter.provider\" is \"ollama\"."
},
"aiCodeCommenter.verbosity": {
"type": "string",
"enum": [
"minimal",
"standard",
"detailed"
],
"enumDescriptions": [
"Only comment non-obvious logic and public APIs.",
"Comment functions, classes, and non-trivial logic.",
"Thoroughly document purpose, edge cases, and complexity."
],
"default": "standard",
"description": "How much commentary to generate."
},
"aiCodeCommenter.autoFormat": {
"type": "boolean",
"default": true,
"description": "Run Prettier on the affected code after inserting comments (where supported)."
},
"aiCodeCommenter.improveExistingComments": {
"type": "boolean",
"default": true,
"description": "Allow the AI to rewrite vague or outdated existing comments, not just add new ones."
}
}
}
},
"activationEvents": [],
"scripts": {
"compile": "node esbuild.js",
"watch": "node esbuild.js --watch",
"package": "node esbuild.js --production",
"vscode:prepublish": "npm run package",
"typecheck": "tsc --noEmit -p ./",
"lint": "eslint src",
"format": "prettier --write \"src/**/*.ts\"",
"vsce:package": "vsce package",
"pretest": "npm run compile",
"test": "node ./test/runTest.js"
},
"devDependencies": {
"@eslint/js": "^9.9.0",
"@types/mocha": "^10.0.10",
"@types/node": "^20.14.0",
"@types/vscode": "^1.85.0",
"@typescript-eslint/eslint-plugin": "^8.0.0",
"@typescript-eslint/parser": "^8.0.0",
"@vscode/test-electron": "^3.0.0",
"@vscode/vsce": "^3.0.0",
"esbuild": "^0.23.0",
"eslint": "^9.9.0",
"mocha": "^11.7.6",
"typescript": "^5.5.0"
},
"dependencies": {
"@google/generative-ai": "^0.21.0",
"prettier": "^3.3.0"
}
}