feat: add support for code context in more commands (#1162)

* feat: add support for claude code context

- code context for:
  - add-task
  - update-subtask
  - update-task
  - update

* feat: fix CI and format + refactor

* chore: format

* chore: fix broken tests

* chore: fix test
This commit is contained in:
Ralph Khreish
2025-08-28 18:05:31 +02:00
committed by GitHub
parent db720a954d
commit 4dad2fd613
17 changed files with 112 additions and 25 deletions

View File

@@ -427,6 +427,19 @@ function getResearchProvider(explicitRoot = null) {
return getModelConfigForRole('research', explicitRoot).provider;
}
/**
* Check if Claude Code is being used as the provider
* @param {boolean} useResearch - Whether to check research provider or main provider
* @param {string|null} projectRoot - Project root path (optional)
* @returns {boolean} True if Claude Code is the current provider
*/
function isClaudeCode(useResearch = false, projectRoot = null) {
const currentProvider = useResearch
? getResearchProvider(projectRoot)
: getMainProvider(projectRoot);
return currentProvider === CUSTOM_PROVIDERS.CLAUDE_CODE;
}
function getResearchModelId(explicitRoot = null) {
return getModelConfigForRole('research', explicitRoot).modelId;
}
@@ -983,6 +996,7 @@ export {
getResearchModelId,
getResearchMaxTokens,
getResearchTemperature,
isClaudeCode,
getFallbackProvider,
getFallbackModelId,
getFallbackMaxTokens,