Skip to content

fix speckit issue for trae#2112

Merged
mnriem merged 6 commits intogithub:mainfrom
JiaKangning002:speckit-for-trae
Apr 7, 2026
Merged

fix speckit issue for trae#2112
mnriem merged 6 commits intogithub:mainfrom
JiaKangning002:speckit-for-trae

Conversation

@JiaKangning002
Copy link
Copy Markdown
Contributor

@JiaKangning002 JiaKangning002 commented Apr 7, 2026

Description

Fixed an issue with the speckit tool's support for the Trae agent. Registered the skpeckit command as skills.

Testing

  • Tested locally with uv run specify --help
  • Ran existing tests with uv sync && uv run pytest
  • Tested with a sample project (if applicable)
    trae-agent-test

AI Disclosure

  • I did not use AI assistance for this contribution
  • I did use AI assistance (describe below)

@JiaKangning002 JiaKangning002 requested a review from mnriem as a code owner April 7, 2026 10:19
@JiaKangning002 JiaKangning002 changed the title Speckit for trae fix speckit issue for trae Apr 7, 2026
@mnriem mnriem requested a review from Copilot April 7, 2026 12:31
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Trae integration to be treated as a skills-based agent (agentskills layout) and aligns generated context/documentation paths for Trae.

Changes:

  • Convert Trae integration to a SkillsIntegration, switching output from .trae/rules commands to .trae/skills skills layout.
  • Update Trae context file naming to .trae/rules/project_rules.md across integration scripts and agent-context updaters.
  • Adjust CLI “next steps” command display to show Trae’s skill invocation style.
Show a summary per file
File Description
tests/test_agent_config_consistency.py Updates Trae expectations for skills-based config/registrar behavior.
tests/integrations/test_integration_trae.py Updates Trae integration test constants (currently only context path).
src/specify_cli/presets.py Notes Trae as a native skills agent in preset skill registration comments.
src/specify_cli/integrations/trae/scripts/update-context.sh Updates Trae context filename comment to project_rules.md.
src/specify_cli/integrations/trae/scripts/update-context.ps1 Updates Trae context filename comment to project_rules.md.
src/specify_cli/integrations/trae/init.py Converts Trae to SkillsIntegration and switches commands dir/subdir to skills.
src/specify_cli/init.py Adds Trae to skills-mode display logic for next-steps panel.
scripts/powershell/update-agent-context.ps1 Points Trae context target to .trae/rules/project_rules.md.
scripts/bash/update-agent-context.sh Points Trae context target to .trae/rules/project_rules.md.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comments suppressed due to low confidence (1)

tests/integrations/test_integration_trae.py:12

  • TraeIntegration is now a SkillsIntegration (writes speckit-/SKILL.md), but this test still uses MarkdownIntegrationTests and still expects COMMANDS_SUBDIR/REGISTRAR_DIR under .trae/rules. Update the mixin to SkillsIntegrationTests and align constants with the integration config (commands_subdir skills, registrar dir .trae/skills).
class TestTraeIntegration(MarkdownIntegrationTests):
    KEY = "trae"
    FOLDER = ".trae/"
    COMMANDS_SUBDIR = "rules"
    REGISTRAR_DIR = ".trae/rules"
    CONTEXT_FILE = ".trae/rules/project_rules.md"

  • Files reviewed: 9/9 changed files
  • Comments generated: 2

Copy link
Copy Markdown
Collaborator

@mnriem mnriem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please address Copilot feedback. If not applicable, please explain why

@JiaKangning002
Copy link
Copy Markdown
Contributor Author

@copilot apply changes based on the comments in this thread

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Trae integration to use a skills-based layout (agentskills.io-style speckit-<name>/SKILL.md) and aligns related configuration, context-file paths, and CLI messaging so Trae behaves like other native skills agents in spec-kit.

Changes:

  • Convert TraeIntegration to a SkillsIntegration targeting .trae/skills with /SKILL.md outputs.
  • Rename Trae’s agent context target from .trae/rules/AGENTS.md to .trae/rules/project_rules.md across scripts/tests.
  • Update “next steps” CLI display logic to show skills invocation syntax for Trae.
Show a summary per file
File Description
tests/test_agent_config_consistency.py Updates Trae config expectations to skills (commands_subdir=skills, /SKILL.md).
tests/integrations/test_integration_trae.py Updates Trae integration test expectations for the new context file path (but still needs skills migration updates).
src/specify_cli/presets.py Notes Trae among native skills agents in preset skill registration comments.
src/specify_cli/integrations/trae/scripts/update-context.sh Updates Trae wrapper script comment to point at project_rules.md.
src/specify_cli/integrations/trae/scripts/update-context.ps1 Updates Trae wrapper script comment to point at project_rules.md.
src/specify_cli/integrations/trae/init.py Switches Trae integration to SkillsIntegration and updates dirs/extensions accordingly.
src/specify_cli/init.py Treats Trae as a native skills agent for usage display formatting.
scripts/powershell/update-agent-context.ps1 Updates Trae context file path variable to project_rules.md.
scripts/bash/update-agent-context.sh Updates Trae context file path variable to project_rules.md.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 9/9 changed files
  • Comments generated: 4

jiakangning and others added 2 commits April 7, 2026 21:19
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Trae integration to use the skills-based layout (SKILL.md) rather than the prior rules/markdown command layout, aligning Trae with other native skills agents in the CLI.

Changes:

  • Switch Trae integration from MarkdownIntegration to SkillsIntegration and update its directories/config (.trae/skills, /SKILL.md).
  • Update Trae-related tests to use the shared skills integration test suite and new expected paths.
  • Update Trae context file naming to .trae/rules/project_rules.md in integration wrappers and shared context update scripts.
Show a summary per file
File Description
tests/test_agent_config_consistency.py Updates Trae expectations for commands subdir and skills sentinel extension.
tests/integrations/test_integration_trae.py Switches Trae integration tests to the skills-based test mixin and updates expected paths.
src/specify_cli/presets.py Updates comment to include Trae as a native skills agent.
src/specify_cli/integrations/trae/scripts/update-context.sh Updates Trae context filename in wrapper script header.
src/specify_cli/integrations/trae/scripts/update-context.ps1 Updates Trae context filename in wrapper script header.
src/specify_cli/integrations/trae/init.py Converts Trae integration to SkillsIntegration, updates registrar/config paths, and adds --skills option default.
src/specify_cli/init.py Updates “next steps” display logic to treat Trae as skills-invocation mode.
scripts/powershell/update-agent-context.ps1 Updates Trae context target path to .trae/rules/project_rules.md.
scripts/bash/update-agent-context.sh Updates Trae context target path to .trae/rules/project_rules.md.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 9/9 changed files
  • Comments generated: 2

@JiaKangning002 JiaKangning002 requested a review from mnriem April 7, 2026 13:38
@mnriem mnriem merged commit 6536bc4 into github:main Apr 7, 2026
12 checks passed
@mnriem
Copy link
Copy Markdown
Collaborator

mnriem commented Apr 7, 2026

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants