πŸ’Ύ Archived View for gemi.dev β€Ί gemini-mailing-list β€Ί 001036.gmi captured on 2023-11-04 at 13:17:01. Gemini links have been rewritten to link to archived content

View Raw

More Information

➑️ Next capture (2023-12-28)

-=-=-=-=-=-=-

chat over gemini (or, let's play with streaming text)

Omar Polo <op (a) omarpolo.com>

Hello,

One of the things that I love about text/gemini is how it's easy to
parse, and being it line-based it's also really easy to stream it.  When
I started working on telescope, the idea of being able to stream content
was present in the design of the parser from the first draft -- it also
fit nicely with separation in multiple processes (one process does the
fetching, another one the rendering, and messages are sent from one proc
to the other.)  But other than knowing from the code that it should
work, I never played with this aspect of text/gemini.

Fast forward various months, I've just watched the "Why gemini" video by
Tomasino and I got an urge to build something with streaming text.  I'm
attaching a very, very simple CGI script that streams text/gemini to
build an interactive chatroom.

The idea is similar to the one presented by solderpunk in "A vision for
gemini applications"

gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-gemi
ni-applications.gmi

and, frankly, I'm quite disappointed nobody has built something like
this before.  (or at least I haven't been able to find it.  I know
kensanata has made some experiments with a mush, but I haven't played
with it (yet))

The idea is to provide two pages: one that accepts input via the
response code 10 and appends to a file, the second is a literal `tail
-f'.  Simple, but it works, and it's immediate.  As soon as someone
sends something, all the clients reading from `tail -f' gets the
message.

(the various `tail -f' gets eventually killed by a SIGPIPE when the
client closes the connection and the server closes the script stdout.
It could take a while due to the buffering, but can be worked out.  I
don't know if servers are expected to kill the spawned scripts -- I
don't recall anything from the RFC -- but I'm probably wrong.  gmid
anyway doesn't kill the scripts, it let UNIX do its things with signals.
Feature or bug?  dunno.)

It doesn't require a client certificates, but uses the subject of it if
provided.  There's a check that can be de-commented to enforce the usage
of client certificates.

I'm hosting a demo at

	gemini://gemini.omarpolo.com/cgi/lets-chat

but I don't promise to keep it online.  It's a quick-n-dirty script
(less than 50 lines of -hopefully- portable sh), probably filled with
bugs, wrote only to be a demonstration.  I don't want to moderate it
if/when people write things.  It's really easy to host it locally, for
e.g. using gmid (disclaimer: I'm the author)

	$ gmid -x '*' .

from the same directory where you saved the script.

It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
Amfora don't seem to support streaming, or maybe I have an old version.
Elpher doesn't stream by design.

I hope this inspires someone to build amazing things with the streaming
capability of text/gemini.  There are a lot of possibilities, for
instance capsules like station could stream the feed, or the
notification page; it could be better than clients continously
refreshing the page.  Think of it like some sort of "websockets" but for
humans ;)

Gemini clients could "ring" or use some other kind of mechanism to
inform the user that more content is available in a page (for
e.g. Telescope adds a `!'  before the tab title.)

Cheers,

Omar Polo


P.S.: this is also a partial reply to the talkat spec.  I love seeing
what creative things folks are building, and I really hope the best for
mbays and their idea (if I got the paternity correctly :P), but I also
like the idea of doing these sort of things over gemini.  On one hand I
don't want to push gemini over its boundaries, on the other I love doing
that :)

Link to individual message.

Michael Lazar <lazar.michael22 (a) gmail.com>

On Mon, Oct 4, 2021 at 2:45 PM Omar Polo <op at omarpolo.com> wrote:
> The idea is similar to the one presented by solderpunk in "A vision for
> gemini applications"
>
> gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-ge
mini-applications.gmi
>
> and, frankly, I'm quite disappointed nobody has built something like
> this before.  (or at least I haven't been able to find it.  I know
> kensanata has made some experiments with a mush, but I haven't played
> with it (yet))
>
> The idea is to provide two pages: one that accepts input via the
> response code 10 and appends to a file, the second is a literal `tail
> -f'.  Simple, but it works, and it's immediate.  As soon as someone
> sends something, all the clients reading from `tail -f' gets the
> message.

Looks familiar!

gemini://chat.mozz.us/

(source code) https://github.com/michael-lazar/jetforce/blob/master/examples/chatroom.py

- Michael

Link to individual message.

Omar Polo <op (a) omarpolo.com>


Michael Lazar <lazar.michael22 at gmail.com> writes:

> On Mon, Oct 4, 2021 at 2:45 PM Omar Polo <op at omarpolo.com> wrote:
>> The idea is similar to the one presented by solderpunk in "A vision for
>> gemini applications"
>>
>> gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-g
emini-applications.gmi
>>
>> and, frankly, I'm quite disappointed nobody has built something like
>> this before.  (or at least I haven't been able to find it.  I know
>> kensanata has made some experiments with a mush, but I haven't played
>> with it (yet))
>>
>> The idea is to provide two pages: one that accepts input via the
>> response code 10 and appends to a file, the second is a literal `tail
>> -f'.  Simple, but it works, and it's immediate.  As soon as someone
>> sends something, all the clients reading from `tail -f' gets the
>> message.
>
> Looks familiar!
>
> gemini://chat.mozz.us/
>
> (source code) 
https://github.com/michael-lazar/jetforce/blob/master/examples/chatroom.py
>
> - Michael

Oooouch sorry, I haven't seen that!

The idea of a infinite loop of redirects for providing input is really
clever, and of course the implementation is way, way better!

Thanks for sharing! ;)

Link to individual message.

almaember <almaember (a) disroot.org>

I've seen a proof of concept like this a while ago, although I don't 
remember where or when exactly.
-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.

Link to individual message.

Anna β€œCyberTailor” <cyber (a) sysrq.in>

On 2021-10-04 16:40, Michael Lazar wrote:
> Looks familiar!
> 
> gemini://chat.mozz.us/

There was another chatroom:

gemini://chatroom.yysu.xyz

(source code: https://git.sr.ht/~ysu/gemini-chatroom)

but it's offline now.

Link to individual message.

indieterminacy@libre.brussels <indieterminacy (a) libre.brussels>


Omar Polo <op at omarpolo.com> writes:

> Hello,
>
> One of the things that I love about text/gemini is how it's easy to
> parse, and being it line-based it's also really easy to stream it.  When
> I started working on telescope, the idea of being able to stream content
> was present in the design of the parser from the first draft -- it also
> fit nicely with separation in multiple processes (one process does the
> fetching, another one the rendering, and messages are sent from one proc
> to the other.)  But other than knowing from the code that it should
> work, I never played with this aspect of text/gemini.
>
> Fast forward various months, I've just watched the "Why gemini" video by
> Tomasino and I got an urge to build something with streaming text.  I'm
> attaching a very, very simple CGI script that streams text/gemini to
> build an interactive chatroom.
>
> The idea is similar to the one presented by solderpunk in "A vision for
> gemini applications"
>
> gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-ge
mini-applications.gmi
>
> and, frankly, I'm quite disappointed nobody has built something like
> this before.  (or at least I haven't been able to find it.  I know
> kensanata has made some experiments with a mush, but I haven't played
> with it (yet))
>
> The idea is to provide two pages: one that accepts input via the
> response code 10 and appends to a file, the second is a literal `tail
> -f'.  Simple, but it works, and it's immediate.  As soon as someone
> sends something, all the clients reading from `tail -f' gets the
> message.
>
> (the various `tail -f' gets eventually killed by a SIGPIPE when the
> client closes the connection and the server closes the script stdout.
> It could take a while due to the buffering, but can be worked out.  I
> don't know if servers are expected to kill the spawned scripts -- I
> don't recall anything from the RFC -- but I'm probably wrong.  gmid
> anyway doesn't kill the scripts, it let UNIX do its things with signals.
> Feature or bug?  dunno.)
>
> It doesn't require a client certificates, but uses the subject of it if
> provided.  There's a check that can be de-commented to enforce the usage
> of client certificates.
>
> I'm hosting a demo at
>
> 	gemini://gemini.omarpolo.com/cgi/lets-chat
>

Thanks for experimenting with this.

Ive been wondering about treating feeds as if it was a REPL, for group
projects. Ive never gotten around to IRC but Id like to think people
interoperate well in streams with heterogenous coding tricks.

> but I don't promise to keep it online.  It's a quick-n-dirty script
> (less than 50 lines of -hopefully- portable sh), probably filled with
> bugs, wrote only to be a demonstration.  I don't want to moderate it
> if/when people write things.  It's really easy to host it locally, for
> e.g. using gmid (disclaimer: I'm the author)
>
> 	$ gmid -x '*' .
>
> from the same directory where you saved the script.
>
> It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
> Amfora don't seem to support streaming, or maybe I have an old version.
> Elpher doesn't stream by design.

Its always nice getting titbits comparing the browsers. Are there any
good research points which evaluate such things in a tabular way
(something I had originally planned but I lost 2 weeks with earache)?
>
> I hope this inspires someone to build amazing things with the streaming
> capability of text/gemini.  There are a lot of possibilities, for
> instance capsules like station could stream the feed, or the
> notification page; it could be better than clients continously
> refreshing the page.  Think of it like some sort of "websockets" but for
> humans ;)
>
> Gemini clients could "ring" or use some other kind of mechanism to
> inform the user that more content is available in a page (for
> e.g. Telescope adds a `!'  before the tab title.)
>

A nice touch!

> Cheers,
>
> Omar Polo
>
>
> P.S.: this is also a partial reply to the talkat spec.  I love seeing
> what creative things folks are building, and I really hope the best for
> mbays and their idea (if I got the paternity correctly :P), but I also
> like the idea of doing these sort of things over gemini.  On one hand I
> don't want to push gemini over its boundaries, on the other I love doing
> that :)
>
>
> [2. application/octet-stream; lets-chat]...


Jonathan McHugh
indieterminacy at libre.brussels

Link to individual message.

Chris McGee <newton688 (a) gmail.com>

I feel that using Gemini for things where other established protocols are
better designed for the task is a path to it becoming just another web
protocol that tries to do everything, poorly. A much better model might be
something like Unix where you have tools that do their thing well and also
work together well.

Having said that, I wonder if Gemtext would be a decent marking down
content in a chat system, such as IRC, or in a great many other places in a
Gemini fediverse. Line orientation could be a nice feature there.

On Mon, Oct 4, 2021 at 2:45 PM Omar Polo <op at omarpolo.com> wrote:

> Hello,
>
> One of the things that I love about text/gemini is how it's easy to
> parse, and being it line-based it's also really easy to stream it.  When
> I started working on telescope, the idea of being able to stream content
> was present in the design of the parser from the first draft -- it also
> fit nicely with separation in multiple processes (one process does the
> fetching, another one the rendering, and messages are sent from one proc
> to the other.)  But other than knowing from the code that it should
> work, I never played with this aspect of text/gemini.
>
> Fast forward various months, I've just watched the "Why gemini" video by
> Tomasino and I got an urge to build something with streaming text.  I'm
> attaching a very, very simple CGI script that streams text/gemini to
> build an interactive chatroom.
>
> The idea is similar to the one presented by solderpunk in "A vision for
> gemini applications"
>
> gemini://
> gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-gemini-applications.gmi
>
> and, frankly, I'm quite disappointed nobody has built something like
> this before.  (or at least I haven't been able to find it.  I know
> kensanata has made some experiments with a mush, but I haven't played
> with it (yet))
>
> The idea is to provide two pages: one that accepts input via the
> response code 10 and appends to a file, the second is a literal `tail
> -f'.  Simple, but it works, and it's immediate.  As soon as someone
> sends something, all the clients reading from `tail -f' gets the
> message.
>
> (the various `tail -f' gets eventually killed by a SIGPIPE when the
> client closes the connection and the server closes the script stdout.
> It could take a while due to the buffering, but can be worked out.  I
> don't know if servers are expected to kill the spawned scripts -- I
> don't recall anything from the RFC -- but I'm probably wrong.  gmid
> anyway doesn't kill the scripts, it let UNIX do its things with signals.
> Feature or bug?  dunno.)
>
> It doesn't require a client certificates, but uses the subject of it if
> provided.  There's a check that can be de-commented to enforce the usage
> of client certificates.
>
> I'm hosting a demo at
>
>         gemini://gemini.omarpolo.com/cgi/lets-chat
>
> but I don't promise to keep it online.  It's a quick-n-dirty script
> (less than 50 lines of -hopefully- portable sh), probably filled with
> bugs, wrote only to be a demonstration.  I don't want to moderate it
> if/when people write things.  It's really easy to host it locally, for
> e.g. using gmid (disclaimer: I'm the author)
>
>         $ gmid -x '*' .
>
> from the same directory where you saved the script.
>
> It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
> Amfora don't seem to support streaming, or maybe I have an old version.
> Elpher doesn't stream by design.
>
> I hope this inspires someone to build amazing things with the streaming
> capability of text/gemini.  There are a lot of possibilities, for
> instance capsules like station could stream the feed, or the
> notification page; it could be better than clients continously
> refreshing the page.  Think of it like some sort of "websockets" but for
> humans ;)
>
> Gemini clients could "ring" or use some other kind of mechanism to
> inform the user that more content is available in a page (for
> e.g. Telescope adds a `!'  before the tab title.)
>
> Cheers,
>
> Omar Polo
>
>
> P.S.: this is also a partial reply to the talkat spec.  I love seeing
> what creative things folks are building, and I really hope the best for
> mbays and their idea (if I got the paternity correctly :P), but I also
> like the idea of doing these sort of things over gemini.  On one hand I
> don't want to push gemini over its boundaries, on the other I love doing
> that :)
>
>
>

Link to individual message.

The Gnuserland <gnuserland (a) mailbox.org>

Nice man!

It is cool looking all you awesome dudes so inspired, let you continue 
to rock with Gemini!!!

Gemini == <3

TGL

> Message: 6
> Date: Mon, 04 Oct 2021 18:10:27 +0200
> From: Omar Polo <op at omarpolo.com>
> To: gemini at lists.orbitalfox.eu
> Subject: chat over gemini (or, let's play with streaming text)
> Message-ID: <87ilycsk8z.fsf at omarpolo.com>
> Content-Type: text/plain; charset="us-ascii"
>
> Hello,
>
> One of the things that I love about text/gemini is how it's easy to
> parse, and being it line-based it's also really easy to stream it.  When
> I started working on telescope, the idea of being able to stream content
> was present in the design of the parser from the first draft -- it also
> fit nicely with separation in multiple processes (one process does the
> fetching, another one the rendering, and messages are sent from one proc
> to the other.)  But other than knowing from the code that it should
> work, I never played with this aspect of text/gemini.
>
> Fast forward various months, I've just watched the "Why gemini" video by
> Tomasino and I got an urge to build something with streaming text.  I'm
> attaching a very, very simple CGI script that streams text/gemini to
> build an interactive chatroom.
>
> The idea is similar to the one presented by solderpunk in "A vision for
> gemini applications"
>
> gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-ge
mini-applications.gmi
>
> and, frankly, I'm quite disappointed nobody has built something like
> this before.  (or at least I haven't been able to find it.  I know
> kensanata has made some experiments with a mush, but I haven't played
> with it (yet))
>
> The idea is to provide two pages: one that accepts input via the
> response code 10 and appends to a file, the second is a literal `tail
> -f'.  Simple, but it works, and it's immediate.  As soon as someone
> sends something, all the clients reading from `tail -f' gets the
> message.
>
> (the various `tail -f' gets eventually killed by a SIGPIPE when the
> client closes the connection and the server closes the script stdout.
> It could take a while due to the buffering, but can be worked out.  I
> don't know if servers are expected to kill the spawned scripts -- I
> don't recall anything from the RFC -- but I'm probably wrong.  gmid
> anyway doesn't kill the scripts, it let UNIX do its things with signals.
> Feature or bug?  dunno.)
>
> It doesn't require a client certificates, but uses the subject of it if
> provided.  There's a check that can be de-commented to enforce the usage
> of client certificates.
>
> I'm hosting a demo at
>
> 	gemini://gemini.omarpolo.com/cgi/lets-chat
>
> but I don't promise to keep it online.  It's a quick-n-dirty script
> (less than 50 lines of -hopefully- portable sh), probably filled with
> bugs, wrote only to be a demonstration.  I don't want to moderate it
> if/when people write things.  It's really easy to host it locally, for
> e.g. using gmid (disclaimer: I'm the author)
>
> 	$ gmid -x '*' .
>
> from the same directory where you saved the script.
>
> It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
> Amfora don't seem to support streaming, or maybe I have an old version.
> Elpher doesn't stream by design.
>
> I hope this inspires someone to build amazing things with the streaming
> capability of text/gemini.  There are a lot of possibilities, for
> instance capsules like station could stream the feed, or the
> notification page; it could be better than clients continously
> refreshing the page.  Think of it like some sort of "websockets" but for
> humans ;)
>
> Gemini clients could "ring" or use some other kind of mechanism to
> inform the user that more content is available in a page (for
> e.g. Telescope adds a `!'  before the tab title.)
>
> Cheers,
>
> Omar Polo
>
>
> P.S.: this is also a partial reply to the talkat spec.  I love seeing
> what creative things folks are building, and I really hope the best for
> mbays and their idea (if I got the paternity correctly :P), but I also
> like the idea of doing these sort of things over gemini.  On one hand I
> don't want to push gemini over its boundaries, on the other I love doing
> that :)
>
>

Link to individual message.

Omar Polo <op (a) omarpolo.com>


Chris McGee <newton688 at gmail.com> writes:

> I feel that using Gemini for things where other established protocols 
are better designed for the task is a path to it becoming just
> another web protocol that tries to do everything, poorly. A much better 
model might be something like Unix where you have tools
> that do their thing well and also work together well.

I agree with that, there are surely better way to chat!

I was mostly trying to get some fun with the streaming ability of
text/gemini, and the chat was the first thing I could think of, and also
the easiest to implement (it's crap written in less than 50 lines of
shell, including blanks.)  It's more of a demonstration of how easy and
useful streaming pages can be.

Thinking of text/gemini as a (possibly) "infinite" stream of lines is an
interesting perks of gemini, and can unlock the creation of simple, yet
very powerful applications.  Think of a fediverse instance over gemini,
or maybe station, with a "feed" page that streams toots/posts.  Or a
news site that streams live events.

Now, not every capsule needs to stream pages of course, but I was mostly
trying to bring up the point again, and see if it stimulates someone
to create something more useful. ;-)

> Having said that, I wonder if Gemtext would be a decent marking down 
content in a chat system, such as IRC, or in a great many
> other places in a Gemini fediverse. Line orientation could be a nice feature there.
>
> On Mon, Oct 4, 2021 at 2:45 PM Omar Polo <op at omarpolo.com> wrote:
>
>  Hello,
>
>  One of the things that I love about text/gemini is how it's easy to
>  parse, and being it line-based it's also really easy to stream it.  When
>  I started working on telescope, the idea of being able to stream content
>  was present in the design of the parser from the first draft -- it also
>  fit nicely with separation in multiple processes (one process does the
>  fetching, another one the rendering, and messages are sent from one proc
>  to the other.)  But other than knowing from the code that it should
>  work, I never played with this aspect of text/gemini.
>
>  Fast forward various months, I've just watched the "Why gemini" video by
>  Tomasino and I got an urge to build something with streaming text.  I'm
>  attaching a very, very simple CGI script that streams text/gemini to
>  build an interactive chatroom.
>
>  The idea is similar to the one presented by solderpunk in "A vision for
>  gemini applications"
>
>  gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-g
emini-applications.gmi
>
>  and, frankly, I'm quite disappointed nobody has built something like
>  this before.  (or at least I haven't been able to find it.  I know
>  kensanata has made some experiments with a mush, but I haven't played
>  with it (yet))
>
>  The idea is to provide two pages: one that accepts input via the
>  response code 10 and appends to a file, the second is a literal `tail
>  -f'.  Simple, but it works, and it's immediate.  As soon as someone
>  sends something, all the clients reading from `tail -f' gets the
>  message.
>
>  (the various `tail -f' gets eventually killed by a SIGPIPE when the
>  client closes the connection and the server closes the script stdout.
>  It could take a while due to the buffering, but can be worked out.  I
>  don't know if servers are expected to kill the spawned scripts -- I
>  don't recall anything from the RFC -- but I'm probably wrong.  gmid
>  anyway doesn't kill the scripts, it let UNIX do its things with signals.
>  Feature or bug?  dunno.)
>
>  It doesn't require a client certificates, but uses the subject of it if
>  provided.  There's a check that can be de-commented to enforce the usage
>  of client certificates.
>
>  I'm hosting a demo at
>
>          gemini://gemini.omarpolo.com/cgi/lets-chat
>
>  but I don't promise to keep it online.  It's a quick-n-dirty script
>  (less than 50 lines of -hopefully- portable sh), probably filled with
>  bugs, wrote only to be a demonstration.  I don't want to moderate it
>  if/when people write things.  It's really easy to host it locally, for
>  e.g. using gmid (disclaimer: I'm the author)
>
>          $ gmid -x '*' .
>
>  from the same directory where you saved the script.
>
>  It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
>  Amfora don't seem to support streaming, or maybe I have an old version.
>  Elpher doesn't stream by design.
>
>  I hope this inspires someone to build amazing things with the streaming
>  capability of text/gemini.  There are a lot of possibilities, for
>  instance capsules like station could stream the feed, or the
>  notification page; it could be better than clients continously
>  refreshing the page.  Think of it like some sort of "websockets" but for
>  humans ;)
>
>  Gemini clients could "ring" or use some other kind of mechanism to
>  inform the user that more content is available in a page (for
>  e.g. Telescope adds a `!'  before the tab title.)
>
>  Cheers,
>
>  Omar Polo
>
>  P.S.: this is also a partial reply to the talkat spec.  I love seeing
>  what creative things folks are building, and I really hope the best for
>  mbays and their idea (if I got the paternity correctly :P), but I also
>  like the idea of doing these sort of things over gemini.  On one hand I
>  don't want to push gemini over its boundaries, on the other I love doing
>  that :)

Link to individual message.

mbays <mbays (a) sdf.org>



>I hope this inspires someone to build amazing things with the streaming
>capability of text/gemini.  There are a lot of possibilities, for
>instance capsules like station could stream the feed, or the
>notification page; it could be better than clients continously
>refreshing the page.

DNA implemented thread notifications this way:
=> gemini://nixo.xyz/notifications

My game server SGGS also uses this kind of technique -- after making 
your move, you leave the stream open, and once your opponent moves the 
new game state will be appended to the stream; also any chat messages 
are sent in real time.

=> gemini://gemini.thegonz.net/sggs sggs

Unlike mozz's and your approaches, this uses a single page which 
includes the links to chat/move. There's one annoyance with this 
single-page approach to real-time chat: there's no way to know for sure 
which messages were received by the user before they interrupted the 
stream to make a new request. So you either have to accept that some 
messages might be lost, or you have to repeat messages. I took the 
safest approach: every chat message sent during the streaming period 
after the initial response is sent again as part of the initial response 
to the next request.

>Gemini clients could "ring" or use some other kind of mechanism to
>inform the user that more content is available in a page (for
>e.g. Telescope adds a `!'  before the tab title.)

For terminal clients, I don't think this is really necessary, because 
monitoring for movement is something you can leave up to the terminal 
/ terminal multiplexer (e.g. the 'monitor' command in GNU screen). But 
it doesn't hurt.

By the way, anyone wanting an easy way to test their (favourite) 
client's handling of streams can use this test page:
=> gemini://gemini.thegonz.net/sggs/streamtest

Link to individual message.

Chris McGee <newton688 (a) gmail.com>

Sorry, I didn't mean to knock on a fun hacking project. I hope you have
fun. :)

I can see the draw of gemtext's line orientation in streaming chat systems.
Maybe it would be a good fit for IRC also?

Chris

On Tue, Oct 5, 2021 at 11:24 AM Omar Polo <op at omarpolo.com> wrote:

>
> Chris McGee <newton688 at gmail.com> writes:
>
> > I feel that using Gemini for things where other established protocols
> are better designed for the task is a path to it becoming just
> > another web protocol that tries to do everything, poorly. A much better
> model might be something like Unix where you have tools
> > that do their thing well and also work together well.
>
> I agree with that, there are surely better way to chat!
>
> I was mostly trying to get some fun with the streaming ability of
> text/gemini, and the chat was the first thing I could think of, and also
> the easiest to implement (it's crap written in less than 50 lines of
> shell, including blanks.)  It's more of a demonstration of how easy and
> useful streaming pages can be.
>
> Thinking of text/gemini as a (possibly) "infinite" stream of lines is an
> interesting perks of gemini, and can unlock the creation of simple, yet
> very powerful applications.  Think of a fediverse instance over gemini,
> or maybe station, with a "feed" page that streams toots/posts.  Or a
> news site that streams live events.
>
> Now, not every capsule needs to stream pages of course, but I was mostly
> trying to bring up the point again, and see if it stimulates someone
> to create something more useful. ;-)
>
> > Having said that, I wonder if Gemtext would be a decent marking down
> content in a chat system, such as IRC, or in a great many
> > other places in a Gemini fediverse. Line orientation could be a nice
> feature there.
> >
> > On Mon, Oct 4, 2021 at 2:45 PM Omar Polo <op at omarpolo.com> wrote:
> >
> >  Hello,
> >
> >  One of the things that I love about text/gemini is how it's easy to
> >  parse, and being it line-based it's also really easy to stream it.  When
> >  I started working on telescope, the idea of being able to stream content
> >  was present in the design of the parser from the first draft -- it also
> >  fit nicely with separation in multiple processes (one process does the
> >  fetching, another one the rendering, and messages are sent from one proc
> >  to the other.)  But other than knowing from the code that it should
> >  work, I never played with this aspect of text/gemini.
> >
> >  Fast forward various months, I've just watched the "Why gemini" video by
> >  Tomasino and I got an urge to build something with streaming text.  I'm
> >  attaching a very, very simple CGI script that streams text/gemini to
> >  build an interactive chatroom.
> >
> >  The idea is similar to the one presented by solderpunk in "A vision for
> >  gemini applications"
> >
> >  gemini://
> gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for-gemini-applications.gmi
> >
> >  and, frankly, I'm quite disappointed nobody has built something like
> >  this before.  (or at least I haven't been able to find it.  I know
> >  kensanata has made some experiments with a mush, but I haven't played
> >  with it (yet))
> >
> >  The idea is to provide two pages: one that accepts input via the
> >  response code 10 and appends to a file, the second is a literal `tail
> >  -f'.  Simple, but it works, and it's immediate.  As soon as someone
> >  sends something, all the clients reading from `tail -f' gets the
> >  message.
> >
> >  (the various `tail -f' gets eventually killed by a SIGPIPE when the
> >  client closes the connection and the server closes the script stdout.
> >  It could take a while due to the buffering, but can be worked out.  I
> >  don't know if servers are expected to kill the spawned scripts -- I
> >  don't recall anything from the RFC -- but I'm probably wrong.  gmid
> >  anyway doesn't kill the scripts, it let UNIX do its things with signals.
> >  Feature or bug?  dunno.)
> >
> >  It doesn't require a client certificates, but uses the subject of it if
> >  provided.  There's a check that can be de-commented to enforce the usage
> >  of client certificates.
> >
> >  I'm hosting a demo at
> >
> >          gemini://gemini.omarpolo.com/cgi/lets-chat
> >
> >  but I don't promise to keep it online.  It's a quick-n-dirty script
> >  (less than 50 lines of -hopefully- portable sh), probably filled with
> >  bugs, wrote only to be a demonstration.  I don't want to moderate it
> >  if/when people write things.  It's really easy to host it locally, for
> >  e.g. using gmid (disclaimer: I'm the author)
> >
> >          $ gmid -x '*' .
> >
> >  from the same directory where you saved the script.
> >
> >  It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
> >  Amfora don't seem to support streaming, or maybe I have an old version.
> >  Elpher doesn't stream by design.
> >
> >  I hope this inspires someone to build amazing things with the streaming
> >  capability of text/gemini.  There are a lot of possibilities, for
> >  instance capsules like station could stream the feed, or the
> >  notification page; it could be better than clients continously
> >  refreshing the page.  Think of it like some sort of "websockets" but for
> >  humans ;)
> >
> >  Gemini clients could "ring" or use some other kind of mechanism to
> >  inform the user that more content is available in a page (for
> >  e.g. Telescope adds a `!'  before the tab title.)
> >
> >  Cheers,
> >
> >  Omar Polo
> >
> >  P.S.: this is also a partial reply to the talkat spec.  I love seeing
> >  what creative things folks are building, and I really hope the best for
> >  mbays and their idea (if I got the paternity correctly :P), but I also
> >  like the idea of doing these sort of things over gemini.  On one hand I
> >  don't want to push gemini over its boundaries, on the other I love doing
> >  that :)
>
>

Link to individual message.

Anna β€œCyberTailor” <cyber (a) sysrq.in>

On 2021-10-05 17:15, Omar Polo wrote:
> Thinking of text/gemini as a (possibly) "infinite" stream of lines is an
> interesting perks of gemini, and can unlock the creation of simple, yet
> very powerful applications.  Think of a fediverse instance over gemini,
> or maybe station, with a "feed" page that streams toots/posts.  Or a
> news site that streams live events.
> 
> Now, not every capsule needs to stream pages of course, but I was mostly
> trying to bring up the point again, and see if it stimulates someone
> to create something more useful. ;-)

There's a capsule that renders ASCII art using streaming with
intentional slowdown to emulate modem-like download speed.

gemini://ansi.hrtk.in/

Link to individual message.

The Gnuserland <gnuserland (a) mailbox.org>

Hi Geminauts,

I would add another bunch of words about this...

I really watch with admiration anytime someone is pushing the boundaries 
of the protocol to its limits, I think is smart and useful, I don't feel 
upset or annoying, on the contrary I think it has the beneficial effect 
to understand better what we can achieve or what we can not with Gemini.

This effort of creativity is totally different to propose changes to the 
protocols thus I really encourage all the people with such expertise to 
continue to experiment with Gemini wherever your creativity leads you!

A big thank you to each and everyone of you!!!

TGL


On 10/6/21 7:00 AM, gemini-request at lists.orbitalfox.eu wrote:
> Send Gemini mailing list submissions to
> 	gemini at lists.orbitalfox.eu
>
> To subscribe or unsubscribe via the World Wide Web, visit
> 	https://lists.orbitalfox.eu/listinfo/gemini
> or, via email, send a message with subject or body 'help' to
> 	gemini-request at lists.orbitalfox.eu
>
> You can reach the person managing the list at
> 	gemini-owner at lists.orbitalfox.eu
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Gemini digest..."
>
>
> Today's Topics:
>
>     1. Re: chat over gemini (or, let's play with streaming text)
>        (Omar Polo)
>     2. Re: chat over gemini (or, let's play with streaming text) (mbays)
>     3. Re: chat over gemini (or, let's play with streaming text)
>        (Chris McGee)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Tue, 05 Oct 2021 17:15:10 +0200
> From: Omar Polo <op at omarpolo.com>
> To: Chris McGee <newton688 at gmail.com>
> Cc: gemini at lists.orbitalfox.eu
> Subject: Re: chat over gemini (or, let's play with streaming text)
> Message-ID: <87o883sdej.fsf at omarpolo.com>
> Content-Type: text/plain
>
>
> Chris McGee <newton688 at gmail.com> writes:
>
>> I feel that using Gemini for things where other established protocols 
are better designed for the task is a path to it becoming just
>> another web protocol that tries to do everything, poorly. A much better 
model might be something like Unix where you have tools
>> that do their thing well and also work together well.
> I agree with that, there are surely better way to chat!
>
> I was mostly trying to get some fun with the streaming ability of
> text/gemini, and the chat was the first thing I could think of, and also
> the easiest to implement (it's crap written in less than 50 lines of
> shell, including blanks.)  It's more of a demonstration of how easy and
> useful streaming pages can be.
>
> Thinking of text/gemini as a (possibly) "infinite" stream of lines is an
> interesting perks of gemini, and can unlock the creation of simple, yet
> very powerful applications.  Think of a fediverse instance over gemini,
> or maybe station, with a "feed" page that streams toots/posts.  Or a
> news site that streams live events.
>
> Now, not every capsule needs to stream pages of course, but I was mostly
> trying to bring up the point again, and see if it stimulates someone
> to create something more useful. ;-)
>
>> Having said that, I wonder if Gemtext would be a decent marking down 
content in a chat system, such as IRC, or in a great many
>> other places in a Gemini fediverse. Line orientation could be a nice feature there.
>>
>> On Mon, Oct 4, 2021 at 2:45 PM Omar Polo <op at omarpolo.com> wrote:
>>
>>   Hello,
>>
>>   One of the things that I love about text/gemini is how it's easy to
>>   parse, and being it line-based it's also really easy to stream it.  When
>>   I started working on telescope, the idea of being able to stream content
>>   was present in the design of the parser from the first draft -- it also
>>   fit nicely with separation in multiple processes (one process does the
>>   fetching, another one the rendering, and messages are sent from one proc
>>   to the other.)  But other than knowing from the code that it should
>>   work, I never played with this aspect of text/gemini.
>>
>>   Fast forward various months, I've just watched the "Why gemini" video by
>>   Tomasino and I got an urge to build something with streaming text.  I'm
>>   attaching a very, very simple CGI script that streams text/gemini to
>>   build an interactive chatroom.
>>
>>   The idea is similar to the one presented by solderpunk in "A vision for
>>   gemini applications"
>>
>>   gemini://gemini.circumlunar.space/users/solderpunk/gemlog/a-vision-for
-gemini-applications.gmi
>>
>>   and, frankly, I'm quite disappointed nobody has built something like
>>   this before.  (or at least I haven't been able to find it.  I know
>>   kensanata has made some experiments with a mush, but I haven't played
>>   with it (yet))
>>
>>   The idea is to provide two pages: one that accepts input via the
>>   response code 10 and appends to a file, the second is a literal `tail
>>   -f'.  Simple, but it works, and it's immediate.  As soon as someone
>>   sends something, all the clients reading from `tail -f' gets the
>>   message.
>>
>>   (the various `tail -f' gets eventually killed by a SIGPIPE when the
>>   client closes the connection and the server closes the script stdout.
>>   It could take a while due to the buffering, but can be worked out.  I
>>   don't know if servers are expected to kill the spawned scripts -- I
>>   don't recall anything from the RFC -- but I'm probably wrong.  gmid
>>   anyway doesn't kill the scripts, it let UNIX do its things with signals.
>>   Feature or bug?  dunno.)
>>
>>   It doesn't require a client certificates, but uses the subject of it if
>>   provided.  There's a check that can be de-commented to enforce the usage
>>   of client certificates.
>>
>>   I'm hosting a demo at
>>
>>           gemini://gemini.omarpolo.com/cgi/lets-chat
>>
>>   but I don't promise to keep it online.  It's a quick-n-dirty script
>>   (less than 50 lines of -hopefully- portable sh), probably filled with
>>   bugs, wrote only to be a demonstration.  I don't want to moderate it
>>   if/when people write things.  It's really easy to host it locally, for
>>   e.g. using gmid (disclaimer: I'm the author)
>>
>>           $ gmid -x '*' .
>>
>>   from the same directory where you saved the script.
>>
>>   It seems to work with Telescope, Tinmop and Lagrange.  Kristall and
>>   Amfora don't seem to support streaming, or maybe I have an old version.
>>   Elpher doesn't stream by design.
>>
>>   I hope this inspires someone to build amazing things with the streaming
>>   capability of text/gemini.  There are a lot of possibilities, for
>>   instance capsules like station could stream the feed, or the
>>   notification page; it could be better than clients continously
>>   refreshing the page.  Think of it like some sort of "websockets" but for
>>   humans ;)
>>
>>   Gemini clients could "ring" or use some other kind of mechanism to
>>   inform the user that more content is available in a page (for
>>   e.g. Telescope adds a `!'  before the tab title.)
>>
>>   Cheers,
>>
>>   Omar Polo
>>
>>   P.S.: this is also a partial reply to the talkat spec.  I love seeing
>>   what creative things folks are building, and I really hope the best for
>>   mbays and their idea (if I got the paternity correctly :P), but I also
>>   like the idea of doing these sort of things over gemini.  On one hand I
>>   don't want to push gemini over its boundaries, on the other I love doing
>>   that :)
>
>

Link to individual message.

---

Previous Thread: Video: Why Gemini?

Next Thread: [Tech] Gemini and the DNS