hdsp-jupyter-extension 2.0.19__py3-none-any.whl → 2.0.20__py3-none-any.whl

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.
Files changed (48) hide show
  1. agent_server/langchain/agent_prompts/planner_prompt.py +3 -0
  2. agent_server/langchain/custom_middleware.py +0 -17
  3. agent_server/langchain/llm_factory.py +37 -5
  4. agent_server/langchain/logging_utils.py +41 -16
  5. agent_server/langchain/models/__init__.py +5 -0
  6. agent_server/langchain/models/gpt_oss_chat.py +351 -0
  7. agent_server/langchain/prompts.py +1 -0
  8. agent_server/routers/langchain_agent.py +10 -0
  9. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/build_log.json +1 -1
  10. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/package.json +2 -2
  11. jupyter_ext/labextension/static/lib_index_js.1917fbaea37d75dc69b3.js → hdsp_jupyter_extension-2.0.20.data/data/share/jupyter/labextensions/hdsp-agent/static/lib_index_js.90f80cb80187de8c5ae5.js +71 -6
  12. hdsp_jupyter_extension-2.0.20.data/data/share/jupyter/labextensions/hdsp-agent/static/lib_index_js.90f80cb80187de8c5ae5.js.map +1 -0
  13. hdsp_jupyter_extension-2.0.19.data/data/share/jupyter/labextensions/hdsp-agent/static/remoteEntry.d686ab71eb65b5ef8f15.js → hdsp_jupyter_extension-2.0.20.data/data/share/jupyter/labextensions/hdsp-agent/static/remoteEntry.586bf5521d043cdd37b8.js +3 -3
  14. jupyter_ext/labextension/static/remoteEntry.d686ab71eb65b5ef8f15.js.map → hdsp_jupyter_extension-2.0.20.data/data/share/jupyter/labextensions/hdsp-agent/static/remoteEntry.586bf5521d043cdd37b8.js.map +1 -1
  15. {hdsp_jupyter_extension-2.0.19.dist-info → hdsp_jupyter_extension-2.0.20.dist-info}/METADATA +1 -1
  16. {hdsp_jupyter_extension-2.0.19.dist-info → hdsp_jupyter_extension-2.0.20.dist-info}/RECORD +46 -44
  17. jupyter_ext/_version.py +1 -1
  18. jupyter_ext/labextension/build_log.json +1 -1
  19. jupyter_ext/labextension/package.json +2 -2
  20. hdsp_jupyter_extension-2.0.19.data/data/share/jupyter/labextensions/hdsp-agent/static/lib_index_js.1917fbaea37d75dc69b3.js → jupyter_ext/labextension/static/lib_index_js.90f80cb80187de8c5ae5.js +71 -6
  21. jupyter_ext/labextension/static/lib_index_js.90f80cb80187de8c5ae5.js.map +1 -0
  22. jupyter_ext/labextension/static/{remoteEntry.d686ab71eb65b5ef8f15.js → remoteEntry.586bf5521d043cdd37b8.js} +3 -3
  23. hdsp_jupyter_extension-2.0.19.data/data/share/jupyter/labextensions/hdsp-agent/static/remoteEntry.d686ab71eb65b5ef8f15.js.map → jupyter_ext/labextension/static/remoteEntry.586bf5521d043cdd37b8.js.map +1 -1
  24. hdsp_jupyter_extension-2.0.19.data/data/share/jupyter/labextensions/hdsp-agent/static/lib_index_js.1917fbaea37d75dc69b3.js.map +0 -1
  25. jupyter_ext/labextension/static/lib_index_js.1917fbaea37d75dc69b3.js.map +0 -1
  26. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/etc/jupyter/jupyter_server_config.d/hdsp_jupyter_extension.json +0 -0
  27. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/install.json +0 -0
  28. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/frontend_styles_index_js.96745acc14125453fba8.js +0 -0
  29. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/frontend_styles_index_js.96745acc14125453fba8.js.map +0 -0
  30. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/node_modules_emotion_use-insertion-effect-with-fallbacks_dist_emotion-use-insertion-effect-wi-3ba6b80.c095373419d05e6f141a.js +0 -0
  31. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/node_modules_emotion_use-insertion-effect-with-fallbacks_dist_emotion-use-insertion-effect-wi-3ba6b80.c095373419d05e6f141a.js.map +0 -0
  32. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/node_modules_emotion_use-insertion-effect-with-fallbacks_dist_emotion-use-insertion-effect-wi-3ba6b81.61e75fb98ecff46cf836.js +0 -0
  33. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/node_modules_emotion_use-insertion-effect-with-fallbacks_dist_emotion-use-insertion-effect-wi-3ba6b81.61e75fb98ecff46cf836.js.map +0 -0
  34. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/style.js +0 -0
  35. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_babel_runtime_helpers_esm_extends_js-node_modules_emotion_serialize_dist-051195.e2553aab0c3963b83dd7.js +0 -0
  36. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_babel_runtime_helpers_esm_extends_js-node_modules_emotion_serialize_dist-051195.e2553aab0c3963b83dd7.js.map +0 -0
  37. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_emotion_cache_dist_emotion-cache_browser_development_esm_js.24edcc52a1c014a8a5f0.js +0 -0
  38. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_emotion_cache_dist_emotion-cache_browser_development_esm_js.24edcc52a1c014a8a5f0.js.map +0 -0
  39. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_emotion_react_dist_emotion-react_browser_development_esm_js.19ecf6babe00caff6b8a.js +0 -0
  40. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_emotion_react_dist_emotion-react_browser_development_esm_js.19ecf6babe00caff6b8a.js.map +0 -0
  41. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_emotion_styled_dist_emotion-styled_browser_development_esm_js.661fb5836f4978a7c6e1.js +0 -0
  42. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_emotion_styled_dist_emotion-styled_browser_development_esm_js.661fb5836f4978a7c6e1.js.map +0 -0
  43. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_mui_material_index_js.985697e0162d8d088ca2.js +0 -0
  44. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_mui_material_index_js.985697e0162d8d088ca2.js.map +0 -0
  45. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_mui_material_utils_createSvgIcon_js.1f5038488cdfd8b3a85d.js +0 -0
  46. {hdsp_jupyter_extension-2.0.19.data → hdsp_jupyter_extension-2.0.20.data}/data/share/jupyter/labextensions/hdsp-agent/static/vendors-node_modules_mui_material_utils_createSvgIcon_js.1f5038488cdfd8b3a85d.js.map +0 -0
  47. {hdsp_jupyter_extension-2.0.19.dist-info → hdsp_jupyter_extension-2.0.20.dist-info}/WHEEL +0 -0
  48. {hdsp_jupyter_extension-2.0.19.dist-info → hdsp_jupyter_extension-2.0.20.dist-info}/licenses/LICENSE +0 -0
@@ -2295,7 +2295,7 @@ const ChatPanel = (0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)(({ apiServic
2295
2295
  }
2296
2296
  }
2297
2297
  const formatted = files.map((file) => {
2298
- const icon = file.isDir ? _utils_icons__WEBPACK_IMPORTED_MODULE_8__.Icons.folder : _utils_icons__WEBPACK_IMPORTED_MODULE_8__.Icons.file;
2298
+ const icon = file.isDir ? '[DIR]' : '[FILE]';
2299
2299
  const sizeInfo = file.isDir ? '' : ` (${file.size} bytes)`;
2300
2300
  return `${icon} ${file.path}${file.isDir ? '/' : sizeInfo}`;
2301
2301
  }).join('\n');
@@ -4240,6 +4240,8 @@ const SettingsPanel = ({ onClose, onSave, currentConfig }) => {
4240
4240
  const [vllmEndpoint, setVllmEndpoint] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initConfig.vllm?.endpoint || 'http://localhost:8000/v1');
4241
4241
  const [vllmApiKey, setVllmApiKey] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initConfig.vllm?.apiKey || '');
4242
4242
  const [vllmModel, setVllmModel] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initConfig.vllm?.model || 'meta-llama/Llama-2-7b-chat-hf');
4243
+ const [vllmUseResponsesApi, setVllmUseResponsesApi] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(Boolean(initConfig.vllm?.useResponsesApi));
4244
+ const [vllmTemperature, setVllmTemperature] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initConfig.vllm?.temperature ?? 0.0);
4243
4245
  // OpenAI settings
4244
4246
  const [openaiApiKey, setOpenaiApiKey] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initConfig.openai?.apiKey || '');
4245
4247
  const [openaiModel, setOpenaiModel] = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(initConfig.openai?.model || 'gpt-4');
@@ -4282,6 +4284,8 @@ const SettingsPanel = ({ onClose, onSave, currentConfig }) => {
4282
4284
  setVllmEndpoint(currentConfig.vllm?.endpoint || 'http://localhost:8000/v1');
4283
4285
  setVllmApiKey(currentConfig.vllm?.apiKey || '');
4284
4286
  setVllmModel(currentConfig.vllm?.model || 'meta-llama/Llama-2-7b-chat-hf');
4287
+ setVllmUseResponsesApi(Boolean(currentConfig.vllm?.useResponsesApi));
4288
+ setVllmTemperature(currentConfig.vllm?.temperature ?? 0.0);
4285
4289
  setOpenaiApiKey(currentConfig.openai?.apiKey || '');
4286
4290
  setOpenaiModel(currentConfig.openai?.model || 'gpt-4');
4287
4291
  setSystemPrompt(currentConfig.systemPrompt || (0,_services_ApiKeyManager__WEBPACK_IMPORTED_MODULE_10__.getDefaultLLMConfig)().systemPrompt || '');
@@ -4310,7 +4314,9 @@ const SettingsPanel = ({ onClose, onSave, currentConfig }) => {
4310
4314
  vllm: {
4311
4315
  endpoint: vllmEndpoint,
4312
4316
  apiKey: vllmApiKey,
4313
- model: vllmModel
4317
+ model: vllmModel,
4318
+ useResponsesApi: vllmUseResponsesApi,
4319
+ temperature: vllmTemperature
4314
4320
  },
4315
4321
  openai: {
4316
4322
  apiKey: openaiApiKey,
@@ -4472,7 +4478,16 @@ const SettingsPanel = ({ onClose, onSave, currentConfig }) => {
4472
4478
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement("input", { type: "password", className: "jp-agent-settings-input", value: vllmApiKey, onChange: (e) => setVllmApiKey(e.target.value), placeholder: "API \uD0A4\uAC00 \uD544\uC694\uD55C \uACBD\uC6B0 \uC785\uB825" })),
4473
4479
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: "jp-agent-settings-group" },
4474
4480
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement("label", { className: "jp-agent-settings-label" }, "\uBAA8\uB378 \uC774\uB984"),
4475
- react__WEBPACK_IMPORTED_MODULE_0___default().createElement("input", { type: "text", className: "jp-agent-settings-input", value: vllmModel, onChange: (e) => setVllmModel(e.target.value), placeholder: "meta-llama/Llama-2-7b-chat-hf" })))),
4481
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("input", { type: "text", className: "jp-agent-settings-input", value: vllmModel, onChange: (e) => setVllmModel(e.target.value), placeholder: "meta-llama/Llama-2-7b-chat-hf" })),
4482
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: "jp-agent-settings-group" },
4483
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("label", { className: "jp-agent-settings-label" }, "Temperature"),
4484
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("input", { type: "number", className: "jp-agent-settings-input", value: vllmTemperature, onChange: (e) => setVllmTemperature(Math.max(0, Math.min(2, parseFloat(e.target.value) || 0))), min: 0, max: 2, step: 0.1, style: { width: '100px' } }),
4485
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("small", { style: { color: '#666', marginLeft: '8px' } }, "0.0 = \uACB0\uC815\uC801, 1.0+ = \uCC3D\uC758\uC801")),
4486
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: "jp-agent-settings-group" },
4487
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("label", { className: "jp-agent-settings-checkbox" },
4488
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("input", { type: "checkbox", checked: vllmUseResponsesApi, onChange: (e) => setVllmUseResponsesApi(e.target.checked) }),
4489
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("span", null, "Use Responses API (/v1/responses)")),
4490
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement("small", { style: { color: '#666', display: 'block', marginTop: '4px' } }, "OpenAI Responses API\uB97C \uC9C0\uC6D0\uD558\uB294 \uC5D4\uB4DC\uD3EC\uC778\uD2B8\uC5D0\uC11C \uC0AC\uC6A9")))),
4476
4491
  provider === 'openai' && (react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: "jp-agent-settings-provider" },
4477
4492
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement("h3", null, "OpenAI \uC124\uC815"),
4478
4493
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", { className: "jp-agent-settings-group" },
@@ -9338,7 +9353,34 @@ class ApiService {
9338
9353
  }
9339
9354
  // Handle token events (streaming LLM response)
9340
9355
  if (data.content) {
9341
- onChunk(data.content);
9356
+ // Filter out raw todos JSON that shouldn't be displayed to users
9357
+ // Pattern: {"todos": [{"content": "...", "status": "..."}, ...]}
9358
+ const contentStr = String(data.content).trim();
9359
+ const isSummaryJson = contentStr.includes('"summary"') && contentStr.includes('"next_items"');
9360
+ // Check if this is a raw todos JSON object (not summary JSON)
9361
+ let isRawTodosJson = false;
9362
+ if (!isSummaryJson && contentStr.includes('"todos"')) {
9363
+ try {
9364
+ const parsed = JSON.parse(contentStr);
9365
+ // Check structure: {todos: [{content, status}, ...]}
9366
+ if (parsed && Array.isArray(parsed.todos) && parsed.todos.length > 0) {
9367
+ const firstTodo = parsed.todos[0];
9368
+ if (firstTodo && 'content' in firstTodo && 'status' in firstTodo) {
9369
+ isRawTodosJson = true;
9370
+ }
9371
+ }
9372
+ }
9373
+ catch {
9374
+ // Not valid JSON, check for partial pattern
9375
+ isRawTodosJson = /"todos"\s*:\s*\[\s*\{[^}]*"content"\s*:/.test(contentStr);
9376
+ }
9377
+ }
9378
+ if (isRawTodosJson) {
9379
+ console.log('[ApiService] Filtered raw todos JSON from display');
9380
+ }
9381
+ else {
9382
+ onChunk(data.content);
9383
+ }
9342
9384
  }
9343
9385
  // Handle tool_call events - pass to handler for cell creation
9344
9386
  if (currentEventType === 'tool_call' && data.tool && onToolCall) {
@@ -9508,7 +9550,30 @@ class ApiService {
9508
9550
  }
9509
9551
  // Content chunks
9510
9552
  if (data.content && onChunk) {
9511
- onChunk(data.content);
9553
+ // Filter out raw todos JSON that shouldn't be displayed to users
9554
+ const contentStr = String(data.content).trim();
9555
+ const isSummaryJson = contentStr.includes('"summary"') && contentStr.includes('"next_items"');
9556
+ let isRawTodosJson = false;
9557
+ if (!isSummaryJson && contentStr.includes('"todos"')) {
9558
+ try {
9559
+ const parsed = JSON.parse(contentStr);
9560
+ if (parsed && Array.isArray(parsed.todos) && parsed.todos.length > 0) {
9561
+ const firstTodo = parsed.todos[0];
9562
+ if (firstTodo && 'content' in firstTodo && 'status' in firstTodo) {
9563
+ isRawTodosJson = true;
9564
+ }
9565
+ }
9566
+ }
9567
+ catch {
9568
+ isRawTodosJson = /"todos"\s*:\s*\[\s*\{[^}]*"content"\s*:/.test(contentStr);
9569
+ }
9570
+ }
9571
+ if (isRawTodosJson) {
9572
+ console.log('[ApiService] Filtered raw todos JSON from display');
9573
+ }
9574
+ else {
9575
+ onChunk(data.content);
9576
+ }
9512
9577
  }
9513
9578
  // Tool call events during resume
9514
9579
  if (currentEventType === 'tool_call' && data.tool && onToolCall) {
@@ -11813,4 +11878,4 @@ __webpack_require__.r(__webpack_exports__);
11813
11878
  /***/ }
11814
11879
 
11815
11880
  }]);
11816
- //# sourceMappingURL=lib_index_js.1917fbaea37d75dc69b3.js.map
11881
+ //# sourceMappingURL=lib_index_js.90f80cb80187de8c5ae5.js.map