question

From IndieWeb


question is a post type for soliciting answer replies, which are then typically up/down voted by others and then displayed underneath the question post ordered by highest positive vote count rather than time ordered.

Why

You would publish a question post in order to both get answers to your question, and get others to vote on the answers in order to collectively sort them by best to worst answer.

How

The markup for publishing a question post is not yet defined, yet you can start with just a normal h-entry, like that for a note post.

Jacky Alciné's Approaches

The latest iteration of this allows for webaction support by marking up the replies and even direct targeting using Webmentions. A more integrated approach could be allowing those links to open a modal/form on the page to submit a Micropub request to the voter's site and allow for an on-site experience for voting.

2019.06.17

On June 17, 2019; Jacky Alciné proposed markup for open-ended and multiple choice questions.

Multiple choice:

<section class="h-entry">
<p class="p-note">How do you feel about my site's new theme?</p>
<ol>
  <li class="p-choice">Not that great.</li>
  <li class="p-choice">I'm undecided.</li>
  <li class="p-choice">I'll make it work.</li>
</ol>
</section>

Open Ended:

<section class="h-entry">
<p class="p-note">How do you feel about my site's new theme?</p>
<span class="p-choice"></span>
</section>

Answer Markup:

<section class="h-entry u-in-reply-to">
  "<span class="p-choice">I'm undecided.</span>" is how
  I answered <a href="URL" class="u-url">the question</a>.
</section>

2022.05.09

After a lot of discussions about how to reply to these things, I ( Jacky Alciné) think using anchor links as a "choice" for multiple choice or just direct replying for open-ended questions will be ideal. It allows for Webmention to be used as the form of delivery, is friendly to static sites and can be sorted on the server to provide a UX similar to other polling options. The following flows are what I think I'll take on for my site to handle polling:

Multiple Choice:

<section class="h-entry">
<p class="p-note">How do you feel about my site's new theme?</p>
<ol>
  <li><a href="#not-good" class="u-choice">Not that great.</a></li>
  <li><a href="#eh" class="u-choice">I'm undecided.</a></li>
  <li><a href="#work" class="u-choice">I'll make it work.</a></li>
</ol>
</section>

Open Ended:

<section class="h-entry">
<p class="p-note">How do you feel about my site's new theme?</p>
<a href="" class="u-choice u-url"></a>
</section>

Answer Markup for a Poll:

<section class="h-entry">
  So, I think <a class="u-choice" href="http://question.example/poll#choice">Choice 1</a> is how I'll vote for <a href="http://question.example/poll" class="u-in-reply-to">the poll</a>.
</section>

Answer Markup for an Open Ended Question:

<section class="h-entry">
  Person asked <a href="http://question.example/poll#choice" class="u-in-reply-to">a question</a>.
  <span class="p-choice">The idea of life is that life is an idea.</span>
</section>

Note: I was looking for some prior art in the ActivityPub spec for polling but couldn't find any.

The biggest difference is that if the original post has only one choice whose URL value is also the URL of the post, it can be considered an open-ended reply.

Silo Examples

See Also