Skip to content

Commit 05087ff

Browse files
MUFFANUJkrassowski
andauthored
Add “Ask AI” action for JS log errors (#231)
* Add “Ask AI” action for JS log errors * update docs & test * Use js-logs 1.3.0 action registry API * Fix Ask AI action visibility in JS logs rows * Refactor implementation * Bump js-logs 1.3.1 * AskAI provider gating * Stabilize route cleanup * update Caption Selector * remove redundant afterEach cleanup in tests * Fix shared runtime tests --------- Co-authored-by: Michał Krassowski <5832902+krassowski@users.noreply.github.com>
1 parent b82af22 commit 05087ff

7 files changed

Lines changed: 407 additions & 173 deletions

File tree

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,10 @@ Plugin Playground supports AI-assisted extension prototyping in both JupyterLite
176176
- [JupyterLite AI documentation](https://jupyterlite-ai.readthedocs.io/en/latest/)
177177
- [Plugin authoring skill for agents](_agents/skills/plugin-authoring/SKILL.md)
178178

179+
### JS Logs Ask AI
180+
181+
Plugin Playground adds an `Ask AI` button to JS Logs entries so you can send error text to JupyterLite AI chat for debugging context. The button appears only on `error`/`critical` entries that include text content, and only when JupyterLite AI is available and a provider is configured.
182+
179183
### Command Insert Modes (Default + AI Prompt)
180184

181185
In the `Commands` tab, each command row includes a split `+` action and a mode dropdown:

binder/environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ dependencies:
2121
# additional packages for demos
2222
# - ipywidgets
2323
- jupyterlab-lsp
24-
- jupyterlab-js-logs>=1.2,<2
24+
- jupyterlab-js-logs>=1.3.1,<2
2525
- jupyterlab-tour>=4,<5
2626
# use the same AI package in Binder and JupyterLite deployments
2727
- jupyterlite-ai>=0.15,<1

docs/environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ dependencies:
1010
- myst-parser
1111
- ipywidgets>=8.0,<9
1212
- jupyterlab>=4.0.0,<5
13-
- jupyterlab-js-logs>=1.2,<2
13+
- jupyterlab-js-logs>=1.3.1,<2
1414
- jupyterlab-tour>=4,<5
1515
- jupyterlab-language-pack-fr-FR
1616
- jupyterlab-language-pack-zh-CN

package.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
"@jupyterlab/filebrowser": "^4.5.5",
6969
"@jupyterlab/fileeditor": "^4.5.5",
7070
"@jupyterlab/settingregistry": "^4.5.5",
71-
"jupyterlab-js-logs": "^1.2.0",
71+
"jupyterlab-js-logs": "^1.3.1",
7272
"raw-loader": "^4.0.2",
7373
"requirejs": "^2.3.6",
7474
"semver": "^7.7.4",
@@ -136,6 +136,11 @@
136136
"extension": true,
137137
"outputDir": "jupyterlab_plugin_playground/labextension",
138138
"schemaDir": "schema",
139+
"sharedPackages": {
140+
"jupyterlab-js-logs": {
141+
"singleton": true
142+
}
143+
},
139144
"disabledExtensions": [
140145
"jupyterlab-tour:default-tours"
141146
]

0 commit comments

Comments
 (0)