* nes: implement eager backup request for async flow
this allows to have a new network request in case the async request fails on rebase
* Fix NES eager backup cancellation handling
* Add compaction support for Responses API context management
* compaction update
* compaction update
* cleaning up for PR
* Updating model list that can be enabled for compaction and enabling experimentation config
* cleaning up variable names
* updates based on review comments
* correcting the failed tests
* skip summarization when compaction is enabled
* fixing unit tests
* updating threshold value for compaction
* fixing test failures
* Add memory viewing command and update chat panel session resource definitions
* refactor: rename memory commands and add clear memories functionality
* add memory show and clear commands to chat tools
* refactor: improve memory clearing logic and add user feedback for no memories found
* nes: tests: fix trailing whitespace sensitivity
* nes: xtab: split promptCrafting.ts up
* nes: recent files: split up into functions
* nes: recent files: more strategies to include recent files
* fix: transform older focal ranges through edit chain in historyEntriesToCodeSnippet
Older history entries' focal ranges (from getNewRanges()) pointed into
stale document states, not the most recent content. Now each older
edit entry's ranges are projected forward through subsequent edits
using StringEdit.applyToOffsetRange(). VisibleRanges entries no longer
contribute focal ranges since their offsets cannot be reliably
transformed.
* add validator
* fix: parseModelConfigString accepts value directly instead of re-reading
parseModelConfigStringSetting was re-reading the config from the service
instead of using the observable-tracked value already passed to callers.
This caused a potential inconsistency: the truthy gate in aggregateModels
and determineDefaultModel used the observable value, but the parsing used
a separate read that could return a different value if config changed
between the two reads.
Renamed to parseModelConfigString and changed to accept the config string
value directly as a parameter.
* fix: track useSlashModels as observable dependency in _modelsObs
useSlashModels was read via a non-observable getExperimentBasedConfig()
call inside the derived _modelsObs computation. This meant changes to
the useSlashModels config would not trigger recomputation of the models
list.
Now read through an observable (_useSlashModelsObs) and passed as a
parameter to aggregateModels, so the derived properly tracks it.
* fix: track undesired models as observable dependency in _currentModelObs
_pickModel was calling _undesiredModelsManager.isUndesiredModelId()
directly — a plain synchronous read not tracked by the observable
system. Changes to the undesired models list would not trigger
_currentModelObs to recompute.
Added onDidChange event to IUndesiredModelsManager (and both
implementations), created an observable from it, and read it through
the reader in the _currentModelObs derived computation. _pickModel now
receives the undesiredModelsManager as a parameter.
* fix: serialize UndesiredModels.Manager operations with TaskQueue
addUndesiredModelId and removeUndesiredModelId did read-then-write
without serialization. Concurrent calls could interleave: the second
reads stale state before the first's write completes, overwriting
the first's change.
Now all mutations are serialized through a TaskQueue, ensuring each
operation reads the latest state after any prior write has completed.
* fix: serialize setCurrentModelId calls with TaskQueue
setCurrentModelId was async with multiple awaits but no serialization.
Concurrent calls (e.g. rapid model switching in the UI picker) could
interleave, corrupting undesired-models state and writing stale
preferred-model config.
Now serialized through a TaskQueue so only one setCurrentModelId runs
at a time, with subsequent calls queued until the previous completes.
* refactor: remove dead fallback in selectedModelConfiguration
_currentModelObs always returns a Model (never undefined) due to
_pickModel's fallback chain. The truthy check and the fallback to
determineDefaultModel were dead code.
* fix: validate JSON.parse result with MODEL_CONFIGURATION_VALIDATOR
JSON.parse result was cast to ModelConfiguration without validation.
Invalid JSON structures (e.g. a plain string or number) would pass
parsing but fail at runtime when accessed as ModelConfiguration.
Now uses the existing MODEL_CONFIGURATION_VALIDATOR to validate the
parsed result and reports validation errors via telemetry.
* fix: do not leak an emitter in UndesiredModels.Manager
* fix test
runStartHooks() and run() both called executeSubagentStartHook() for
subagent requests, causing SubagentStart hooks to fire twice per
subagent invocation. The caller (defaultIntentRequestHandler) always
calls runStartHooks() before run(), so the call in run() was redundant.
Remove the duplicate call from run() since runStartHooks() is the
correct place for start hook execution.
* Add skill name to readFileToolInvoked telemetry
* Rename telemetry field to nameField
---------
Co-authored-by: Harald Kirschner <digitarald@gmail.com>
* Misc improvements to Claude CLI integration
We still aren't shipping this (it would need to be imported in index.ts) but this:
* uses capturing token
* passes through betas
* drops "code" in the language
* feedback
* align notice formatting
* fix test
* nes: logContext: trace log closed by default and shown after trace diagram
* fix naming
* easy arg for constructor
* ghost: send model name telemetry