Skip to content

Conversation

@khaliqgant
Copy link
Collaborator

@khaliqgant khaliqgant commented Dec 20, 2025

User description

Summary

Implements comprehensive support for Claude Code slash commands with all new features from the official documentation.

New Features

1. File Referencing with @

  • Reference files directly in command prompts: @filepath
  • Use with arguments: @$1, @$2
  • Example: Compare @src/old.js with @src/new.js

2. Bash Execution with !

  • Execute bash commands inline: !`command`
  • Requires Bash in allowed-tools
  • Example: Current status: !`git status`

3. Argument Handling

  • $ARGUMENTS - All arguments passed to command
  • $1, $2, $3...$9 - Individual positional arguments
  • argument-hint frontmatter field for documentation

4. Namespacing

  • Organize commands in subdirectories
  • .claude/commands/git/status.md/git.status

Changes

Updated Documentation

  • .claude/skills/creating-claude-commands/SKILL.md
    • Added comprehensive documentation for all new features
    • Multiple real-world examples
    • Best practices and patterns

New Tool

  • .claude/commands/create-slash-command.md
    • Slash command for generating slash commands
    • Includes templates, validation, and examples
    • Use: /create-slash-command <name> [description]

Comprehensive Testing

  • 28 integration tests (all passing)
  • Tests for file referencing (@ syntax)
  • Tests for bash execution (! syntax)
  • Tests for argument handling
  • Tests for frontmatter parsing
  • Tests for round-trip conversions
  • Tests for edge cases

Test Coverage

✓ 28 tests passing
  ✓ Basic slash command features (3)
  ✓ File referencing with @ (3)
  ✓ Bash execution with ! (4)
  ✓ Argument handling (4)
  ✓ Combined features (3)
  ✓ Frontmatter field variations (3)
  ✓ Edge cases (5)
  ✓ Conversion quality (2)

Documentation Reference

Based on: https://code.claude.com/docs/en/slash-commands

🤖 Generated with Claude Code


CodeAnt-AI Description

Add Claude slash command support: file references, inline bash, argument placeholders, namespacing, generator, and integration tests

What Changed

  • Commands can reference files with @ (e.g., @src/file.js and @$1) and those references are preserved through parsing and round-trip conversion
  • Inline bash execution using !... is recognized and preserved; Bash tool permissions (e.g., Bash(git *)) are extracted from frontmatter
  • Argument placeholders ($ARGUMENTS, $1–$9) and argument-hint frontmatter are parsed, preserved, and round-tripped
  • Namespacing via subdirectories is documented (commands in .claude/commands/subdir/name.md map to /subdir.name)
  • Adds a /create-slash-command generator template and extensive documentation updates with examples and best practices
  • Introduces 28 integration tests covering file refs, bash execution, argument handling, frontmatter variations, round-trip conversion, and edge cases

Impact

✅ Clearer slash command templates for authors
✅ Shorter command authoring with generator and examples
✅ Fewer round-trip conversion regressions in command content

💡 Usage Guide

Checking Your Pull Request

Every time you make a pull request, our system automatically looks through it. We check for security issues, mistakes in how you're setting up your infrastructure, and common code problems. We do this to make sure your changes are solid and won't cause any trouble later.

Talking to CodeAnt AI

Got a question or need a hand with something in your pull request? You can easily get in touch with CodeAnt AI right here. Just type the following in a comment on your pull request, and replace "Your question here" with whatever you want to ask:

@codeant-ai ask: Your question here

This lets you have a chat with CodeAnt AI about your pull request, making it easier to understand and improve your code.

Example

@codeant-ai ask: Can you suggest a safer alternative to storing this secret?

Preserve Org Learnings with CodeAnt

You can record team preferences so CodeAnt AI applies them in future reviews. Reply directly to the specific CodeAnt AI suggestion (in the same thread) and replace "Your feedback here" with your input:

@codeant-ai: Your feedback here

This helps CodeAnt AI learn and adapt to your team's coding style and standards.

Example

@codeant-ai: Do not flag unused imports.

Retrigger review

Ask CodeAnt AI to review the PR again, by typing:

@codeant-ai: review

Check Your Repository Health

To analyze the health of your code repository, visit our dashboard at https://app.codeant.ai. This tool helps you identify potential issues and areas for improvement in your codebase, ensuring your repository maintains high standards of code health.

- Add file referencing with @ syntax (@filepath, @$1)
- Add bash execution with ! syntax (!`git status`)
- Add argument handling ($ARGUMENTS, $1-$9)
- Add namespacing documentation (subdirectories → dot notation)
- Create /create-slash-command tool for generating new commands
- Add 28 integration tests covering all slash command features
- Update creating-claude-commands skill with complete documentation

All tests passing. Implements Claude Code slash commands spec:
https://code.claude.com/docs/en/slash-commands

🤖 Generated with [Claude Code](https://claude.com/claude-code)
via [Happy](https://happy.engineering)

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Happy <yesreply@happy.engineering>
@codeant-ai
Copy link

codeant-ai bot commented Dec 20, 2025

CodeAnt AI is reviewing your PR.


Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

@my-senior-dev-pr-review
Copy link

my-senior-dev-pr-review bot commented Dec 20, 2025

🤖 My Senior Dev — Analysis Complete

👤 For @khaliqgant

📁 Expert in packages/ (186 edits) • ⚡ 38th PR this month

View your contributor analytics →


📊 7 files reviewed • 4 high risk • 5 need attention

🚨 High Risk:

  • .beads/issues.jsonl — Potential security vulnerabilities related to credential storage.
  • .claude/commands/create-slash-command.md — The command logic needs robust validation to prevent errors with malformed inputs.
  • prpm.json — Significant alterations in a configuration file that affects multiple components should undergo stringent review.

⚠️ Needs Attention:

  • .claude/skills/creating-claude-commands/SKILL.md — The guidance for command creation is critical to ensure quality and consistency, requiring additional edge case consideration.
  • .claude/commands/create-slash-command.md — Although reviewed for logic, this section also needs a maintenance standpoint for future-proofing.
  • +1 more concerns...

🚀 Open Interactive Review →

The full interface unlocks features not available in GitHub:

  • 💬 AI Chat — Ask questions on any file, get context-aware answers
  • 🔍 Smart Hovers — See symbol definitions and usage without leaving the diff
  • 📚 Code Archeology — Understand how files evolved over time (/archeology)
  • 🎯 Learning Insights — See how this PR compares to similar changes

💬 Chat here: @my-senior-dev explain this change — or try @chaos-monkey @security-auditor @optimizer @skeptic @junior-dev

📖 View all 12 personas & slash commands

You can interact with me by mentioning @my-senior-dev in any comment:

In PR comments or on any line of code:

  • Ask questions about the code or PR
  • Request explanations of specific changes
  • Get suggestions for improvements

Slash commands:

  • /help — Show all available commands
  • /archeology — See the history and evolution of changed files
  • /profile — Performance analysis and suggestions
  • /expertise — Find who knows this code best
  • /personas — List all available AI personas

AI Personas (mention to get their perspective):

Persona Focus
@chaos-monkey 🐵 Edge cases & failure scenarios
@skeptic 🤨 Challenge assumptions
@optimizer Performance & efficiency
@security-auditor 🔒 Security vulnerabilities
@accessibility-advocate Inclusive design
@junior-dev 🌱 Simple explanations
@tech-debt-collector 💳 Code quality & shortcuts
@ux-champion 🎨 User experience
@devops-engineer 🚀 Deployment & scaling
@documentation-nazi 📚 Documentation gaps
@legacy-whisperer 🏛️ Working with existing code
@test-driven-purist Testing & TDD

For the best experience, view this PR on myseniordev.com — includes AI chat, file annotations, and interactive reviews.

@codeant-ai codeant-ai bot added the size:XL This PR changes 500-999 lines, ignoring generated files label Dec 20, 2025
Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

2 issues found across 3 files

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them.


<file name=".claude/skills/creating-claude-commands/SKILL.md">

<violation number="1" location=".claude/skills/creating-claude-commands/SKILL.md:520">
P2: Documentation example has inconsistent variable usage. The descriptive text mentions `$1($2): $ARGUMENTS` but the bash command uses `$1: $ARGUMENTS`, omitting `$2`. Additionally, using `$ARGUMENTS` will include `$1` again, creating duplicate content in the commit message (e.g., `feat: feat add user auth`). Consider using `$1: $2` to match the `argument-hint: &lt;type&gt; &lt;message&gt;`.</violation>
</file>

<file name=".claude/commands/create-slash-command.md">

<violation number="1" location=".claude/commands/create-slash-command.md:31">
P2: Malformed markdown backticks - this will render incorrectly. To show backticks inside inline code, use double backticks with spaces: ``` `` !`command` `` ```.</violation>
</file>

Reply to cubic to teach it or ask questions. Re-run a review with @cubic-dev-ai review this PR


Create conventional commit: $1($2): $ARGUMENTS

!`git add -A && git commit -m "$1: $ARGUMENTS"`
Copy link

@cubic-dev-ai cubic-dev-ai bot Dec 20, 2025

Choose a reason for hiding this comment

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

P2: Documentation example has inconsistent variable usage. The descriptive text mentions $1($2): $ARGUMENTS but the bash command uses $1: $ARGUMENTS, omitting $2. Additionally, using $ARGUMENTS will include $1 again, creating duplicate content in the commit message (e.g., feat: feat add user auth). Consider using $1: $2 to match the argument-hint: <type> <message>.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At .claude/skills/creating-claude-commands/SKILL.md, line 520:

<comment>Documentation example has inconsistent variable usage. The descriptive text mentions `$1($2): $ARGUMENTS` but the bash command uses `$1: $ARGUMENTS`, omitting `$2`. Additionally, using `$ARGUMENTS` will include `$1` again, creating duplicate content in the commit message (e.g., `feat: feat add user auth`). Consider using `$1: $2` to match the `argument-hint: &lt;type&gt; &lt;message&gt;`.</comment>

<file context>
@@ -411,6 +485,42 @@ Add emoji to H1 heading for quick recognition:
+
+Create conventional commit: $1($2): $ARGUMENTS
+
+!`git add -A &amp;&amp; git commit -m &quot;$1: $ARGUMENTS&quot;`
+```
+**Invoke with:** `/git.quick-commit feat &quot;add user auth&quot;`
</file context>
Fix with Cubic

3. **Features to Consider:**
- **Arguments:** Use `$ARGUMENTS`, `$1`, `$2`, etc. for user input
- **File References:** Use `@filepath` to reference files
- **Bash Execution:** Use `!`command`` for inline bash (requires `Bash` in allowed-tools)
Copy link

@cubic-dev-ai cubic-dev-ai bot Dec 20, 2025

Choose a reason for hiding this comment

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

P2: Malformed markdown backticks - this will render incorrectly. To show backticks inside inline code, use double backticks with spaces: `` !`command` ``.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At .claude/commands/create-slash-command.md, line 31:

<comment>Malformed markdown backticks - this will render incorrectly. To show backticks inside inline code, use double backticks with spaces: ``` `` !`command` `` ```.</comment>

<file context>
@@ -0,0 +1,155 @@
+3. **Features to Consider:**
+   - **Arguments:** Use `$ARGUMENTS`, `$1`, `$2`, etc. for user input
+   - **File References:** Use `@filepath` to reference files
+   - **Bash Execution:** Use `!`command`` for inline bash (requires `Bash` in allowed-tools)
+   - **Namespacing:** Use subdirectories for organization (`.claude/commands/category/name.md`)
+
</file context>
Fix with Cubic

Comment on lines +9 to +10
import { validateMarkdown } from '../validation.js';
import type { CanonicalPackage } from '../types/canonical.js';
Copy link

Choose a reason for hiding this comment

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

Suggestion: The imports for validateMarkdown and the CanonicalPackage type are never used in this test file, which is dead code and can cause TypeScript/ESLint failures in configurations that disallow unused locals, as well as adding unnecessary noise for maintainers. [possible bug]

Severity Level: Critical 🚨

Suggested change
import { validateMarkdown } from '../validation.js';
import type { CanonicalPackage } from '../types/canonical.js';
Why it matters? ⭐

Both imports appear at the top of the final file but are never referenced anywhere in the test. Removing them will eliminate dead code and avoid failures in projects with "no-unused-vars" / unused-imports ESLint rules or stricter TS compiler settings. This is a real, actionable cleanup that reduces noise and potential CI failures.

Prompt for AI Agent 🤖
This is a comment left during a code review.

**Path:** packages/converters/src/__tests__/claude-slash-command-integration.test.ts
**Line:** 9:10
**Comment:**
	*Possible Bug: The imports for `validateMarkdown` and the `CanonicalPackage` type are never used in this test file, which is dead code and can cause TypeScript/ESLint failures in configurations that disallow unused locals, as well as adding unnecessary noise for maintainers.

Validate the correctness of the flagged issue. If correct, How can I resolve this? If you propose a fix, implement it and please make it concise.

@codeant-ai
Copy link

codeant-ai bot commented Dec 20, 2025

CodeAnt AI finished reviewing your PR.

@codeant-ai
Copy link

codeant-ai bot commented Dec 20, 2025

💡 Enhance Your PR Reviews

We noticed that 3 feature(s) are not configured for this repository. Enabling these features can help improve your code quality and workflow:

🚦 Quality Gates

Status: Quality Gates are not enabled at the organization level
Learn more about Quality Gates

🎫 Jira Ticket Compliance

Status: Jira credentials file not found. Please configure Jira integration in your settings
Learn more about Jira Integration

⚙️ Custom Rules

Status: No custom rules configured. Add rules via organization settings or .codeant/review.json in your repository
Learn more about Custom Rules


Want to enable these features? Contact your organization admin or check our documentation for setup instructions.

khaliqgant and others added 2 commits December 20, 2025 08:56
Compares slash command implementations across 7 AI coding assistants:
- Claude Code (most features: @, !, $ARGUMENTS, namespacing)
- Cursor (simplest: plain markdown, no frontmatter)
- Factory Droid (best for scripts: markdown + executables)
- OpenCode (template-driven with agent routing)
- Zed (extension-based: Rust/WASM)
- Gemini CLI (standalone TOML: simple but static)
- Codex (AGENTS.md sections)

Includes feature comparison table and practical recommendations.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
via [Happy](https://happy.engineering)

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Happy <yesreply@happy.engineering>
@codeant-ai
Copy link

codeant-ai bot commented Jan 4, 2026

CodeAnt AI is running Incremental review


Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

11 issues found across 73 files (changes from recent commits).

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them.


<file name="packages/registry/migrations/068_add_snippet_subtype.sql">

<violation number="1" location="packages/registry/migrations/068_add_snippet_subtype.sql:8">
P1: Adding this CHECK constraint without `NOT VALID` can lock/scan the entire `packages` table during migration. Use `NOT VALID` + `VALIDATE CONSTRAINT` to reduce blocking in production.</violation>
</file>

<file name=".github/workflows/deploy.yml">

<violation number="1" location=".github/workflows/deploy.yml:509">
P1: Using `--size-only` for HTML files may miss content updates. If an HTML file changes content but stays the same size (e.g., date updates, version strings), it won&#39;t be uploaded. This defeats the purpose of scheduled rebuilds to update pages with latest data. Consider removing `--size-only` for HTML files or using `--exact-timestamps` instead.</violation>

<violation number="2" location=".github/workflows/deploy.yml:573">
P1: Logic bug: `head -15` truncates invalidation paths, conflicting with the &gt;50 threshold logic. If 16-50 files change, only the first 15 will be invalidated, leaving others with stale cached content. Consider increasing to `head -50` to match the threshold or adjusting the threshold logic.</violation>
</file>

<file name=".claude/rules/types.md">

<violation number="1" location=".claude/rules/types.md:40">
P2: Documentation inconsistency: `windsurf` is used as a key in `FORMAT_SUBTYPES` but is not included in the `Format` type definition (`&quot;cursor&quot; | &quot;claude&quot; | &quot;continue&quot;`). This example would cause a TypeScript error and could mislead developers. Either add `&quot;windsurf&quot;` to the `Format` type in the first example, or remove the `windsurf` entry from this example.</violation>
</file>

<file name="packages/converters/src/__tests__/to-codex.test.ts">

<violation number="1" location="packages/converters/src/__tests__/to-codex.test.ts:669">
P2: Test assertion doesn&#39;t verify the claim in the test name. The test is titled &#39;should truncate description to 1024 chars&#39; but only asserts that `...` appears somewhere in the content. Consider adding assertions to verify the actual truncated length, e.g., by checking the description doesn&#39;t contain more than ~1024 &#39;A&#39; characters or by extracting and measuring the description field.</violation>
</file>

<file name="packages/converters/docs/opencode.md">

<violation number="1" location="packages/converters/docs/opencode.md:5">
P2: Inconsistent user-level path for Skills. Agents and Slash Commands use `~/.config/opencode/` but Skills uses `~/.opencode/`. Should likely be `~/.config/opencode/skill/${name}/SKILL.md` for consistency.</violation>
</file>

<file name="packages/cli/src/core/lockfile.ts">

<violation number="1" location="packages/cli/src/core/lockfile.ts:63">
P3: The type `&#39;append&#39; | &#39;prepend&#39; | string` is redundant and provides no type safety since all string literals are assignable to `string`. Consider removing `string` to enforce only valid values, or use a template literal type for the `section:` pattern.</violation>

<violation number="2" location="packages/cli/src/core/lockfile.ts:222">
P1: Location-aware lockfile keys are written for snippets, but integrity/version lookups elsewhere still use non-location keys. This can bypass integrity verification for snippet installs and break locked-version resolution (especially with `--frozen-lockfile`). Ensure all reads/writes for snippet packages consistently include the same `location` (or add fallback lookup logic for legacy/non-location keys).</violation>
</file>

<file name="packages/registry/src/routes/analytics.ts">

<violation number="1" location="packages/registry/src/routes/analytics.ts:15">
P2: Incomplete change: &#39;codex&#39; was added to the format enum here and in the OpenAPI body schema, but the `/popular` endpoint&#39;s `type` query parameter enum at line 454 was not updated. This inconsistency means downloads can be tracked as &#39;codex&#39; format, but users cannot filter popular packages by that format.</violation>
</file>

<file name="packages/registry/src/routes/search.ts">

<violation number="1" location="packages/registry/src/routes/search.ts:12">
P2: Adding &#39;codex&#39; here creates inconsistency with the duplicate `FORMAT_ENUM` in `packages.ts` which doesn&#39;t include &#39;codex&#39;. This causes inconsistent API validation behavior - search endpoints will accept &#39;codex&#39; but package endpoints will reject it. Consider either updating both files, or better yet, import the shared `FORMATS` constant from `@pr-pm/types` as a single source of truth.</violation>
</file>

<file name="packages/cli/src/commands/install.ts">

<violation number="1" location="packages/cli/src/commands/install.ts:358">
P2: Inconsistent default target for snippets in &#39;already installed&#39; check. The hardcoded default &#39;AGENTS.md&#39; may not match the actual package&#39;s configured target from `pkg.snippet.target`, causing the duplicate-installation check to fail for packages with custom targets.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

ALTER TABLE packages DROP CONSTRAINT IF EXISTS packages_subtype_check;

-- Recreate with snippet included
ALTER TABLE packages ADD CONSTRAINT packages_subtype_check
Copy link

@cubic-dev-ai cubic-dev-ai bot Jan 4, 2026

Choose a reason for hiding this comment

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

P1: Adding this CHECK constraint without NOT VALID can lock/scan the entire packages table during migration. Use NOT VALID + VALIDATE CONSTRAINT to reduce blocking in production.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/registry/migrations/068_add_snippet_subtype.sql, line 8:

<comment>Adding this CHECK constraint without `NOT VALID` can lock/scan the entire `packages` table during migration. Use `NOT VALID` + `VALIDATE CONSTRAINT` to reduce blocking in production.</comment>

<file context>
@@ -0,0 +1,9 @@
+ALTER TABLE packages DROP CONSTRAINT IF EXISTS packages_subtype_check;
+
+-- Recreate with snippet included
+ALTER TABLE packages ADD CONSTRAINT packages_subtype_check
+  CHECK (subtype IN (&#39;rule&#39;, &#39;agent&#39;, &#39;skill&#39;, &#39;slash-command&#39;, &#39;prompt&#39;, &#39;workflow&#39;, &#39;tool&#39;, &#39;template&#39;, &#39;collection&#39;, &#39;chatmode&#39;, &#39;hook&#39;, &#39;snippet&#39;));
</file context>
Fix with Cubic

--exclude "*.html" \
--exclude "_next/data/*"
--exclude "_next/data/*" \
--size-only 2>&1) || true
Copy link

@cubic-dev-ai cubic-dev-ai bot Jan 4, 2026

Choose a reason for hiding this comment

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

P1: Using --size-only for HTML files may miss content updates. If an HTML file changes content but stays the same size (e.g., date updates, version strings), it won't be uploaded. This defeats the purpose of scheduled rebuilds to update pages with latest data. Consider removing --size-only for HTML files or using --exact-timestamps instead.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At .github/workflows/deploy.yml, line 509:

<comment>Using `--size-only` for HTML files may miss content updates. If an HTML file changes content but stays the same size (e.g., date updates, version strings), it won&#39;t be uploaded. This defeats the purpose of scheduled rebuilds to update pages with latest data. Consider removing `--size-only` for HTML files or using `--exact-timestamps` instead.</comment>

<file context>
@@ -495,36 +495,90 @@ jobs:
             --exclude &quot;*.html&quot; \
-            --exclude &quot;_next/data/*&quot;
+            --exclude &quot;_next/data/*&quot; \
+            --size-only 2&gt;&amp;1) || true
+          echo &quot;$SYNC_OUTPUT&quot;
+
</file context>
Suggested change
--size-only 2>&1) || true
2>&1) || true
Fix with Cubic

fi
# Convert space-separated paths to JSON array format
PATHS_ARRAY=$(echo "$PATHS" | tr ' ' '\n' | grep -v '^$' | head -15 | jq -R . | jq -s .)
Copy link

@cubic-dev-ai cubic-dev-ai bot Jan 4, 2026

Choose a reason for hiding this comment

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

P1: Logic bug: head -15 truncates invalidation paths, conflicting with the >50 threshold logic. If 16-50 files change, only the first 15 will be invalidated, leaving others with stale cached content. Consider increasing to head -50 to match the threshold or adjusting the threshold logic.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At .github/workflows/deploy.yml, line 573:

<comment>Logic bug: `head -15` truncates invalidation paths, conflicting with the &gt;50 threshold logic. If 16-50 files change, only the first 15 will be invalidated, leaving others with stale cached content. Consider increasing to `head -50` to match the threshold or adjusting the threshold logic.</comment>

<file context>
@@ -495,36 +495,90 @@ jobs:
+          fi
+
+          # Convert space-separated paths to JSON array format
+          PATHS_ARRAY=$(echo &quot;$PATHS&quot; | tr &#39; &#39; &#39;\n&#39; | grep -v &#39;^$&#39; | head -15 | jq -R . | jq -s .)
+          PATH_COUNT=$(echo &quot;$PATHS_ARRAY&quot; | jq &#39;length&#39;)
+
</file context>
Suggested change
PATHS_ARRAY=$(echo "$PATHS" | tr ' ' '\n' | grep -v '^$' | head -15 | jq -R . | jq -s .)
PATHS_ARRAY=$(echo "$PATHS" | tr ' ' '\n' | grep -v '^$' | head -50 | jq -R . | jq -s .)
Fix with Cubic

const result = toCodex(skillPkg);

// Description should be truncated
expect(result.content).toContain('...');
Copy link

@cubic-dev-ai cubic-dev-ai bot Jan 4, 2026

Choose a reason for hiding this comment

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

P2: Test assertion doesn't verify the claim in the test name. The test is titled 'should truncate description to 1024 chars' but only asserts that ... appears somewhere in the content. Consider adding assertions to verify the actual truncated length, e.g., by checking the description doesn't contain more than ~1024 'A' characters or by extracting and measuring the description field.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/converters/src/__tests__/to-codex.test.ts, line 669:

<comment>Test assertion doesn&#39;t verify the claim in the test name. The test is titled &#39;should truncate description to 1024 chars&#39; but only asserts that `...` appears somewhere in the content. Consider adding assertions to verify the actual truncated length, e.g., by checking the description doesn&#39;t contain more than ~1024 &#39;A&#39; characters or by extracting and measuring the description field.</comment>

<file context>
@@ -450,4 +450,253 @@ Old content for my-command
+      const result = toCodex(skillPkg);
+
+      // Description should be truncated
+      expect(result.content).toContain(&#39;...&#39;);
+    });
+
</file context>
Fix with Cubic

packageId: z.string(),
version: z.string().optional(),
format: z.enum(['cursor', 'claude', 'claude-plugin', 'continue', 'windsurf', 'copilot', 'kiro', 'agents.md', 'gemini', 'ruler', 'droid', 'opencode', 'trae', 'aider', 'zencoder', 'replit', 'generic', 'mcp']).optional(),
format: z.enum(['cursor', 'claude', 'claude-plugin', 'continue', 'windsurf', 'copilot', 'kiro', 'agents.md', 'gemini', 'ruler', 'droid', 'opencode', 'codex', 'trae', 'aider', 'zencoder', 'replit', 'generic', 'mcp']).optional(),
Copy link

@cubic-dev-ai cubic-dev-ai bot Jan 4, 2026

Choose a reason for hiding this comment

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

P2: Incomplete change: 'codex' was added to the format enum here and in the OpenAPI body schema, but the /popular endpoint's type query parameter enum at line 454 was not updated. This inconsistency means downloads can be tracked as 'codex' format, but users cannot filter popular packages by that format.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/registry/src/routes/analytics.ts, line 15:

<comment>Incomplete change: &#39;codex&#39; was added to the format enum here and in the OpenAPI body schema, but the `/popular` endpoint&#39;s `type` query parameter enum at line 454 was not updated. This inconsistency means downloads can be tracked as &#39;codex&#39; format, but users cannot filter popular packages by that format.</comment>

<file context>
@@ -12,7 +12,7 @@ import { telemetry } from &#39;../telemetry/index.js&#39;;
   packageId: z.string(),
   version: z.string().optional(),
-  format: z.enum([&#39;cursor&#39;, &#39;claude&#39;, &#39;claude-plugin&#39;, &#39;continue&#39;, &#39;windsurf&#39;, &#39;copilot&#39;, &#39;kiro&#39;, &#39;agents.md&#39;, &#39;gemini&#39;, &#39;ruler&#39;, &#39;droid&#39;, &#39;opencode&#39;, &#39;trae&#39;, &#39;aider&#39;, &#39;zencoder&#39;, &#39;replit&#39;, &#39;generic&#39;, &#39;mcp&#39;]).optional(),
+  format: z.enum([&#39;cursor&#39;, &#39;claude&#39;, &#39;claude-plugin&#39;, &#39;continue&#39;, &#39;windsurf&#39;, &#39;copilot&#39;, &#39;kiro&#39;, &#39;agents.md&#39;, &#39;gemini&#39;, &#39;ruler&#39;, &#39;droid&#39;, &#39;opencode&#39;, &#39;codex&#39;, &#39;trae&#39;, &#39;aider&#39;, &#39;zencoder&#39;, &#39;replit&#39;, &#39;generic&#39;, &#39;mcp&#39;]).optional(),
   client: z.enum([&#39;cli&#39;, &#39;web&#39;, &#39;api&#39;]).optional(),
 });
</file context>
Fix with Cubic


// Reusable enum constants for schema validation
const FORMAT_ENUM = ['cursor', 'claude', 'claude-plugin', 'continue', 'windsurf', 'copilot', 'kiro', 'agents.md', 'gemini', 'ruler', 'droid', 'opencode', 'trae', 'aider', 'zencoder', 'replit', 'generic', 'mcp'] as const;
const FORMAT_ENUM = ['cursor', 'claude', 'claude-plugin', 'continue', 'windsurf', 'copilot', 'kiro', 'agents.md', 'gemini', 'ruler', 'droid', 'opencode', 'codex', 'trae', 'aider', 'zencoder', 'replit', 'generic', 'mcp'] as const;
Copy link

@cubic-dev-ai cubic-dev-ai bot Jan 4, 2026

Choose a reason for hiding this comment

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

P2: Adding 'codex' here creates inconsistency with the duplicate FORMAT_ENUM in packages.ts which doesn't include 'codex'. This causes inconsistent API validation behavior - search endpoints will accept 'codex' but package endpoints will reject it. Consider either updating both files, or better yet, import the shared FORMATS constant from @pr-pm/types as a single source of truth.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At packages/registry/src/routes/search.ts, line 12:

<comment>Adding &#39;codex&#39; here creates inconsistency with the duplicate `FORMAT_ENUM` in `packages.ts` which doesn&#39;t include &#39;codex&#39;. This causes inconsistent API validation behavior - search endpoints will accept &#39;codex&#39; but package endpoints will reject it. Consider either updating both files, or better yet, import the shared `FORMATS` constant from `@pr-pm/types` as a single source of truth.</comment>

<file context>
@@ -9,7 +9,7 @@ import { Package, Format, Subtype } from &#39;../types.js&#39;;
 
 // Reusable enum constants for schema validation
-const FORMAT_ENUM = [&#39;cursor&#39;, &#39;claude&#39;, &#39;claude-plugin&#39;, &#39;continue&#39;, &#39;windsurf&#39;, &#39;copilot&#39;, &#39;kiro&#39;, &#39;agents.md&#39;, &#39;gemini&#39;, &#39;ruler&#39;, &#39;droid&#39;, &#39;opencode&#39;, &#39;trae&#39;, &#39;aider&#39;, &#39;zencoder&#39;, &#39;replit&#39;, &#39;generic&#39;, &#39;mcp&#39;] as const;
+const FORMAT_ENUM = [&#39;cursor&#39;, &#39;claude&#39;, &#39;claude-plugin&#39;, &#39;continue&#39;, &#39;windsurf&#39;, &#39;copilot&#39;, &#39;kiro&#39;, &#39;agents.md&#39;, &#39;gemini&#39;, &#39;ruler&#39;, &#39;droid&#39;, &#39;opencode&#39;, &#39;codex&#39;, &#39;trae&#39;, &#39;aider&#39;, &#39;zencoder&#39;, &#39;replit&#39;, &#39;generic&#39;, &#39;mcp&#39;] as const;
 const SUBTYPE_ENUM = [&#39;rule&#39;, &#39;agent&#39;, &#39;skill&#39;, &#39;slash-command&#39;, &#39;prompt&#39;, &#39;workflow&#39;, &#39;tool&#39;, &#39;template&#39;, &#39;collection&#39;, &#39;chatmode&#39;, &#39;hook&#39;, &#39;plugin&#39;, &#39;extension&#39;, &#39;server&#39;] as const;
 
</file context>
Fix with Cubic

@codeant-ai
Copy link

codeant-ai bot commented Jan 10, 2026

CodeAnt AI is running Incremental review


Thanks for using CodeAnt! 🎉

We're free for open-source projects. if you're enjoying it, help us grow by sharing.

Share on X ·
Reddit ·
LinkedIn

@khaliqgant khaliqgant merged commit b99af7a into main Jan 10, 2026
11 checks passed
@khaliqgant khaliqgant deleted the slash-commands-enhancements branch January 10, 2026 10:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL This PR changes 500-999 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants