Skip to content

AI skills tells AI agent to do automated work manually #495

@Antonytm

Description

@Antonytm

Describe the Bug

The current way of Sitecore development is to create components by hand, but generate a component map automatically. That is a nice and convenient approach. Sitecore has proper tooling for it. But AI skills in the repository tell to do it manually.

The usual scripts config looks like:

    "sitecore-tools:generate-map": "sitecore-tools project component generate-map",
    "sitecore-tools:generate-map:watch": "sitecore-tools project component generate-map --watch",
    "dev": "cross-env NODE_ENV=development npm-run-all --serial sitecore-tools:generate-map sitecore-tools:build --parallel next:dev sitecore-tools:generate-map:watch",

What does it mean:
You either create a component map by running sitecore-tools:generate-map script, or you run sitecore-tools:generate-map:watch that watches your changes and regenerates it in an automated way.

AI skills:
There are a few AI skills that may cause more problems than giving benefits...

My concern:
These skills may be useful if AI agent develops in a completely isolated environment and has access only to code: text files. But that is not the case for 95%-100% of cases. And that is not the case, taking into account how skills are written. Your skills have Run npm run build to verify prompt. It means that it is expected that the environment has access to the command line and can run npm scripts.

Usually, you have a running dev environment and AI agent that works with it. A dev environment is essential because you need to have a feedback loop to achieve decent results with AI agents. It means that the components map is autogenerated without any attention from the AI agent. Also, writing to autogenerated files is error-prone due to race conditions, as to which one will manage first to write to the component map file: AI or npm script.

Or if the environment is not running in dev mode, it is much easier to generate the component map by sitecore-tools:generate-map. It is one sentence in your skill. Run sitecore-tools:generate-map.

Summary:
The skills listed above are bad, because:

  • They pollute the AI context with a lot of text
  • They do things that are already automated
  • They can cause slowing down development and additional errors.

To Reproduce

Open GitHub, review the code:

Expected Behavior

These skills should be absent or simplified to one(few) sentences to run one command line.

Possible Fix

Remove useless skills or rewrite them, asking AI to run component map generation scripts.

Provide environment information

  • Sitecore Version: *
  • Content SDK Version: 2.*
  • Browser Name and version: N/A
  • Operating System and version (desktop or mobile): N/A
  • Link to your project (if available): N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions