Skip to content

ai-bot: render markdown skills in the prompt (CS-11555)#5396

Draft
jurgenwerk wants to merge 2 commits into
mainfrom
cs-11555-ai-bot-render-markdown-skills
Draft

ai-bot: render markdown skills in the prompt (CS-11555)#5396
jurgenwerk wants to merge 2 commits into
mainfrom
cs-11555-ai-bot-render-markdown-skills

Conversation

@jurgenwerk

@jurgenwerk jurgenwerk commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

This makes the assistant get the source-code-editing skill from a markdown SKILL.md file in the skills realm instead of a Skill card, and teaches the bot how to read markdown skills in general.

Two things were needed. First, getEnabledSkills assumed every enabled skill was a card and tried to JSON.parse its content, which blew up on a plain markdown file — so now it recognizes a SKILL.md, uses its body as the instructions and the frontmatter name as the title, and hands it back in the same shape everything downstream already expects (so nothing else had to change). Second, code mode no longer pushes source-code-editing as a card; it enables the markdown file by URL, which the existing skill-enable command already knows how to load.

The other two code-mode skills stay as cards for now. The markdown skill's body is still pushed into the prompt like before — loading it on demand is a later step. And markdown-skill commands aren't wired yet, which is fine here since source-code-editing has none.

Pairs with cardstack/boxel-skills#84 (the skills converted to markdown). Covered by unit tests for the markdown parsing; host and ai-bot type-check clean.

jurgenwerk and others added 2 commits July 3, 2026 10:59
getEnabledSkills assumed every enabled skill was a Skill card and JSON-parsed
its downloaded content, so a skill enabled as a SKILL.md file broke prompt
assembly. Detect markdown skills by file extension and present them in the same
card-shaped form the pipeline already expects — title from the frontmatter
name (falling back to the file name), instructions from the body after the
frontmatter block. skillCardsToMessages and getTools need no changes.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Stop pushing source-code-editing as a Skill card in code mode; enable it by
URL as the markdown SKILL.md in the skills realm instead. UpdateRoomSkillsCommand
already loads .md skills, and the bot now renders them, so its instructions
flow the same way while the source of truth moves to the markdown file. The
other two code-mode skills stay as cards for now.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@github-actions

github-actions Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Preview deployments

Host Test Results

    1 files      1 suites   2h 15m 26s ⏱️
3 376 tests 3 360 ✅ 15 💤 0 ❌ 1 🔥
3 395 runs  3 378 ✅ 15 💤 1 ❌ 1 🔥

Results for commit e4d81c2.

For more details on these errors, see this check.

Realm Server Test Results

    1 files      1 suites   9m 10s ⏱️
1 674 tests 1 674 ✅ 0 💤 0 ❌
1 753 runs  1 753 ✅ 0 💤 0 ❌

Results for commit e4d81c2.

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.

1 participant