feat(author): route 4 hands over the source as a json block or a file, with the build page's plain address
Closes #208.
Route 4, where nothing is built in the chat, no longer hands over a link that carries the source. In ChatGPT on a free account, 0.10.1's link broke: its model wrote spaces raw partway through, so ChatGPT made no link of it (#208). The angle-bracket form that lets a Markdown link hold spaces came out of ChatGPT as [Build and play it](. Now the source goes over in a form the chat's own copy button copies exactly.
What changes
skills/h5p-author/references/build/browser.md, 1.5 KB where it was 2.1. The reply holds:- the whole source, once, in one
jsoncode block; - one line: copy it, open https://missing-elements.github.io/h5p/build/, choose Paste your chat's JSON, paste it in place of the sample's, and press Build. Where the source names files, the page asks for them;
- only where a code tool runs: the source as a
.source.jsonfile too, which the page opens under Or open a file, and the line offering the build archive.
- the whole source, once, in one
- The page's address has nothing after it, and the text says why: a link that carries the source breaks where a chat writes or copies one character of it wrong.
- Outside a chat, the file takes the code block's place.
- Unchanged: routes 1–3 and the compressed link their command prints. The build page keeps reading
#source={…}(missing-elements.github.io#54), which costs nothing. design/author.md: the rule is now Route 4 hands over the source as ajsonblock or a file, with the build page's plain address. It keeps the link attempt as history, with ChatGPT's two failures, and the four places that pointed to the old title point to this one.
Tested
Haiku, the weakest model first, reading the skill through a logging reader. Each reply was scored by machine: its json block parsed, built with h5p-author and verified with h5p-verify, the addresses in it checked, and in runs with a code tool the file it saved compared with the block.
| Run | One json block, built and passed | Plain address, no source link | .source.json, equal to the block | Archive line |
|---|---|---|---|---|
| Question Set, no tools | yes | yes | — | no, rightly |
| Accordion on HTML tags, no tools | yes | yes | — | no, rightly |
True/False naming cat.jpg, no tools | yes | yes | — | no, rightly |
| Ukrainian Question Set, no tools | yes | yes | — | no, rightly |
| Question Set, code tool with no network | yes | yes | yes | yes |
Drag the Words with % and parentheses, code tool with no network | yes | yes | yes | yes |
pnpm test in packages/author passes (184).
Summary by cubic
Route 4 no longer puts the source in a build-page link that a chat could break while writing or copying; it now hands over the source in a json block plus the build page’s plain address for copy and paste.
- When a code tool is available, the reply also includes a
.source.jsonfile and a line offering the build archive. - Outside a chat, the file replaces the code block.
- Routes 1–3 keep their existing compressed links.