Skip to content

Conversation

Copy link

Copilot AI commented Jan 7, 2026

Added Siren-style JSON representation of the albums example to quantify Jiron's token efficiency advantage over traditional API formats.

Changes

  • examples/albums.json - Siren-compliant JSON with properties expanded into name/value object pairs
  • README.md - Added JSON example and token usage comparison table after HTML example

Token Usage

Jiron (pug):  918 chars
JSON:       1,065 chars (+16%)
HTML:       1,434 chars (+56%)

The JSON demonstrates how Siren's object-based property model ({"name": "artist", "value": "Pink Floyd"}) is more verbose than Jiron's inline syntax (li.property.artist Pink Floyd), even when representing identical hypermedia semantics.

Original prompt

This section details on the original issue you should resolve

<issue_title>add json comparison</issue_title>
<issue_description>show what it would look like to see the example code as json, expanding attributes into a child object to compare token usage</issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits January 7, 2026 00:42
Co-authored-by: ericelliott <364727+ericelliott@users.noreply.github.com>
Co-authored-by: ericelliott <364727+ericelliott@users.noreply.github.com>
Copilot AI changed the title [WIP] Add JSON comparison for example code Add JSON comparison to demonstrate token efficiency Jan 7, 2026
Copilot AI requested a review from ericelliott January 7, 2026 00:47
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.

add json comparison

2 participants