AI config logging enhancements#1711
Conversation
There was a problem hiding this comment.
Pull request overview
This PR refactors AI configuration flows so shared utilities return structured results (instead of logging directly), and centralizes user-facing output in the ig ai-config command. It also expands feedback to explain framework detection and which skills source (package vs bundled) is being used.
Changes:
- Refactored AI skills/instructions copy utilities to return per-file action metadata and skills source metadata; moved logging to
ig ai-config. - Enhanced framework detection to log when detection occurs via
package.jsonor.csproj(and updated tests accordingly). - Updated CLI command call sites/tests for the new
ai-config.configure(framework, options)signature and added more output-oriented unit tests.
Reviewed changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| spec/unit/PromptSession-spec.ts | Updates expectations for the new configure(framework, options) call shape. |
| spec/unit/new-spec.ts | Updates expectations for the new configure(framework, options) call shape from new. |
| spec/unit/detect-framework-spec.ts | Adds coverage for framework-detection logging behavior. |
| spec/unit/ai-skills-spec.ts | Updates/extends tests for new return-only copy results (details, sources). |
| spec/unit/ai-config-spec.ts | Adds tests validating new ai-config command logging/verbosity behavior. |
| packages/igx-templates/igx-ts/custom-templates/crm-grid/files/src/app/path/filePrefix.ts | Template changes (currently includes a critical class name placeholder regression). |
| packages/core/util/detect-framework.ts | Adds logging for package.json and .csproj-based detection; updates docs. |
| packages/core/util/ai-skills.ts | Refactors skills/instructions copying to return structured metadata and stop logging internally. |
| packages/cli/lib/PromptSession.ts | Calls AI configure with verbose: false to reduce duplicate/noisy output in guided flows. |
| packages/cli/lib/commands/new.ts | Updates new command to call AI configure with options object. |
| packages/cli/lib/commands/ai-config.ts | Centralizes logging and adds per-file + source feedback + verbosity control. |
| CHANGELOG.md | Documents the improved ig ai-config output and behavior changes. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…ommand This avoids duplicating per-file CRUD messages doubling when called from schematics.
37cfc44 to
bc1eeec
Compare
| try { | ||
| if (destFs.fileExists(dest)) { | ||
| const existingContent = destFs.readFile(dest); | ||
| if (existingContent === newContent) { |
| // for now assume webcomponents as default fallback | ||
| Util.log("Detected Web Components project (from package.json)"); | ||
| return "webcomponents"; |
There was a problem hiding this comment.
Updated the log message to "Assuming Web Components (no Angular/React deps found in package.json)" and adjusted the matching test expectation in commit fix: update misleading WebComponents fallback log message.
…ameworkFromPackageJson
Description
Small refactor to move to the logging into the

ai-configcommand to avoid duplicate file logging in schematics:And additional logging feedback to let users know why a framework was picked (if it was though detection) and which skills source is being used:

Type of Change
Affected Packages
igniteui-cli(packages/cli)@igniteui/cli-core(packages/core)@igniteui/angular-templates(packages/igx-templates)@igniteui/angular-schematics(packages/ng-schematics)@igniteui/mcp-server(packages/igniteui-mcp)Checklist
npm run test)npm run build)npm run lint)Additional Context