RE: https://w3c.social/@w3c/116216070362563670
FWIW, I have been storing Linked Data (including ActivityPub) in an INI like format — because I find INI-like formats more human-friendly (to both read and write) than JSON.
YAML is probably better than JSON, too, in that respects. But I think […]
With ActivityPub / ActivityStreams...
To me, it feels like there should have been something that is a common parent of both 'Object' and 'Link'.
That just had the "name", "nameMap", and "preview" fields (along with "id" and "type, of course) — since that is what 'Object' and 'Link' share in […]
RE: https://mastodon.social/@reiver/112133984854710390
"A guide to implement ActivityPub in a static site (or any website)" by @mapache
maho.dev/2024/02/a-guide-to-imple...
#ActivityPub #ActivityStreams #FediDev #FediDevs #Fediverse
2.6 RDF Blank Nodes RDF blank nodes in Turtle are expressed as _: followed by a blank node label which is a series of name characters. The characters in the label are built upon PN_CHARS_BASE, liberalized as follows: • The characters _ and digits may appear anywhere in a blank node label. • The character . may appear anywhere except the first or last character. • The characters -, U+00B7, U+0300 to U+036F and U+203F to U+2040 are permitted anywhere except the first character.
I suspect that there is an error in the Turtle specification, in the section shown in the screen-shot.
(It relates to JSON-LD, which ActivityPub / ActivityStreams is built on.)
I suspect that "PN_CHARS_BASE" is an error.
Because other parts of other […]
[Original post on mastodon.social]
There is a larger discussion about fixed-point numbers versus floating-point numbers.
And that, ALL programming-languages should have fixed-point numbers built into them.
And that, programmers should be warned against using floating-point numbers in all but a set of very specialized situations […]
This specification allows implementations to set limits on the range and precision of numbers accepted. Since software that implements IEEE 754 binary64 (double precision) numbers [IEEE754] is generally available and widely used, good interoperability can be achieved by implementations that expect no more precision or range than these provide, in the sense that implementations will approximate JSON numbers within the expected precision. A JSON number such as 1E400 or 3.141592653589793238462643383279 may indicate potential interoperability problems, since it suggests that the software that created it expects receiving software to have greater capabilities for numeric magnitude and precision than is widely available.
[JSON vs IETF JSON]
This is likely (directly or indirectly) the fault of a single paragraph in IETF RFC-7159 / RFC-8259 (shown in the attached screen-shot).
(And note that, there is a difference between JSON and IETF JSON. JSON did not have this. IETF JSON […]
[Original post on mastodon.social]
number In the JSON serialization, a number is similar to that used in most programming languages, except that the octal and hexadecimal formats are not used and that leading zeros are not allowed. In the internal representation, a number is equivalent to either a long or double, depending on if the number has a non-zero fractional part (see [WEBIDL]).
This is from the JSON-LD spec.
ActivityPub / ActivityStream are based on JSON-LD.
I think it was a very bad idea for JSON-LD to define "number" this way!
It makes it so numbers with fractional values are inexact & lossy.
This include values that are […]
[Original post on mastodon.social]
In the old blogging software I created back in the 1990s, I had a handful of posts types.
There was a type rich-text oriented post that had a title. (Article)
And, there way another type of rich-text oriented post that did not have a title. (Note)
(There were also other types of posts, but […]
I've seen an ongoing debate between "Note" versus "Article" in ActivityPub / ActivityStreams.
When is something a "Note"‽
When is something an "Article"‽
Personally — I would probably have made the distinction this way.
An "Article" has a title.
A "Note" doesn't have a title.
(In ActivityPub […]
5/
[Fediverse BackUp]
But — for an Activity File to be a "good" format for a BackUp, there would need to be a way to get the Fediverse software to embed the (non-text) media (such as images, audio, video, etc) into an Activity File.
Also —
...
#ActivityPub #ActivityStreams #BackUp #BackUps […]
1/
[Fediverse BackUp]
Could an ActivityPub / ActivityStreams file be a "good" format for backing up a post?
(I.e., what I can an "Activity File" — which has a media-type of "application/activity+json".)
...
#ActivityPub #ActivityStreams #BackUp #BackUps #FediBackUp #FediDev #FediDevs #Fediverse
@hereus.net can only process #ActivityStreams when user is online, because everything is #encrypted, and the only key is the user.
Yet, it still
- Works perfect with #fediverse and
- Keeps #responsiveness even user never uses the app again.
(2/3)
I wish there was a facility (native or in any app, ideally as part of the #ActivityStreams objects) where I could make #notes on #toots, like we can make notes about particular accounts.
I have a bunch of stuff #bookmarked; I have a tool that exports and sorts my bookmarks.. but by the time I […]
"@context": [
"https://www.w3.org/ns/activitystreams",
{
"Quotation": "as:Quotation",
"citation": "as:citation",
"quotation": "as:quotation"
},
],
#ActivityPub #ActivityStreams #FediDev #Fediverse #JSONLD #ObjectTypeQuotation
4/
Apparently, Bookwyrm stores quotations with:
type="Quotation"
And if one Bookwyrm server talks to another Bookwyrm server, then — the ActivityPub / ActivityStreams representation of the quotation will have:
type="Quotation"
...
BUT — if a non-Bookwyrm server talks to a Bookwyrm server […]
3/
Apparently the Bookwyrm developer had the exact same idea!
(Which isn't too surprising.)
...
#ActivityPub #ActivityStreams #FediDev #Fediverse #ObjectTypeNote #ObjectTypeQuotation
2/
How could you represent a quotation in ActivityPub‽
...
I suppose there are 2 major approaches.
Either use an existing Object Type. Maybe:
type="Note"
Or create a new Object Type:
type="Quotation"
...
Here is the interesting thing though —
#ActivityPub #ActivityStreams #FediDev […]
Quotations & the Fediverse / ActivityPub
1/
One thing I used to do a lot on social-media is — post quotations.
Sometimes I was reading a book. And, I would quote things from the book and post it on social-media.
Or I was reading a scholarly paper, or […]
[Original post on mastodon.social]
9/
A regular users might write Markdown like this:
"""
# Hello!
How do you do?
"""
Or write HTML like this:
"""
<article>
<h1>Hello!</h1>
<p>How do you do?</p>
</article>
"""
#ActivityPub #ActivityStreams #FediDev #Fediverse #Markdown #retejo #RDFa
8/
REMEMBER: this is for power-users, not regular users
How would you get ActivityPub / ActivityStreams into HTML using RDFa‽
Like this:
<div vocab="https://www.w3.org/ns/activitystreams#" typeof="Note">
<p property="name">Hello!</p>
<p>How do you do?</p>
</div>
AGAIN, REMEMBER: this is for […]
7/
If you are wondering what RDFa is —
You might be more familiar with OpenGraph.
https://ogp.me/
OpenGraph is usually the thing that causes "preview cards" to be showed for links shared on social-media.
OpenGraph is written in RDFa. Which, in practice, is some special HTML elements added […]
6/
Obviously, beginners are NOT going to do this, but — some power-users may want this level of control.
There are different way this could be done, but — one way might be that power-users could use RDFa to explicitly specify what data from the HTML gets into the ActivityPub / ActivityStreams […]
5/
So, what would be a good user-experience (UX) for power-users be — in a system that automatically creates ActivityPub / ActivityStreams data from HTML and Markdown‽
One thought I had is that power-users could explicitly mark what data from their HTML gets into the ActivityPub / […]
4/
I think one mistake some software does is — they create a good experience for beginners, but have a poor experience for power-users.
And keep in mind that — some beginners become power-users later on.
I think it is important to design for power-users, too, in addition to beginners […]
3/
If a typical user is writing in Markdown, and their Markdown file has a level-1 heading right at the beginning, then —
That could go into the ActivityPub "name" field.
And, similar could be done for HTML, too.
...
But what about power users —
#ActivityPub #ActivityStreams #FediDev […]
2/
What are "good" ways of automatically creating ActivityPub / ActivityStreams data from HTML and Markdown‽
I think the answer depends on who, for example, is writing HTML, and how they are writing it.
For example, is this a typical user? Is this a power-user? Do they know HTML? And if they […]
1/
I have spending time thinking of ways you could automatically create ActivityPub / ActivityStreams data from HTML and Markdown
Most people will probably write in plain UTF-8 text, or Markdown, or HTML
How to do you take that and get it onto the Fediverse and Social Web‽
This isn't just a […]