emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ELPA] New package: jami-bot and org-jami-bot


From: Hanno Perrey
Subject: Re: [ELPA] New package: jami-bot and org-jami-bot
Date: Fri, 12 Jan 2024 16:04:00 +0100

Hej,

I appreciate the discussion on generalizing features offered by Org mode
that my request triggered. However, I am not really in a position to
comment on this -- instead, I would like to clarify some aspects of the
two *jami-bot packages without commenting on the broader direction of
Emacs development.

>   > >> org-jami-bot builds upon jami-bot and extends it with Org mode capture
>   > >> functionality for text messages and images. It allows to schedule 
> agenda
>   > >> items at specific dates, compose multi-measure captures and capture
>   > >> images -- all by sending a message via the GNU Jami messenger.
>
> When I read that, and looking at it again now. I understand this as
> saying that this package is a feature for certain kinds of
> communication from Emacs via Jami.  That seems to be the job that the
> package does.
>
> By contrast, the connection with Org mode seems to be a secondary
> matter -- that this feature interfaces to Emacs: only via Org mode.
> At least, that is what these words imply to me.

I would say that this is a mostly correct interpretation. However, the
package description might not be technically accurate enough for this
discussion: jami-bot deals with all the actual text message and
file/image handling. The latter, for example, will be automatically
downloaded into a customizable directory. The former are parsed for
command strings and functions called to handle these (via abnormal
hooks). Similarly, downloaded files can be further processed by adding
hooks.

This is what org-jami-bot does: it adds hooks to jami-bot for Org
mode-specific features, such as using the capture mechanism. For files,
for example, an Org mode heading is created via the capture mechanism
and a Org mode-style link to the downloaded file is added.

jami-bot therefore offers more of a framework to trigger actions via
Jami messages but it only implements a basic feature set. org-jami-bot,
on the other hand, only adds hooks for a couple of Org mode features but
otherwise relies on the handling provided by jami-bot. It does not
really create any unique features itself.

> If that is true, there is a problem here: a feature which could (and
> should) be more general has been implemented in a limited way -- to
> use the Jami capture feature, you are compelled to do it via Org mode.

While this is technically true, the capture functionality is only a hook
added to jami-bot. It would be very easy to "capture" messages into
plain text files or other formats with only a few lines of code and only
requiring jami-bot.

> Stefan Kangas said I was mistaken, that this package is not really an
> instance of that problem.  Did I get the wrong idea of the package
> from the words I cited above?  He said that the Org part was
> "trivial".  Maybe my understanding of the description is mistaken.

I would not call org-jami-bot "trivial" but it is very light-weight as
all the heavy lifting is done either in jami-bot or (maybe more so) Org
mode.

> The right way to implement Jami capture for Emacs is to integrate it
> in a general way, which does not depend on Org mode.  Then, if you
> like, add another layer to access Jami capture conveniently from Org
> mode.  Doing a good job of this means offering the same festures at
> the same levels, with or without Org mode,

This is exactly what I intended to do with jami-bot and org-jami-bot.
However, with the latter I have not implemented any actual capture
feature, only the "glue" to Org mode's.

I also want to add that note capture is only one option for interacting
with Emacs via Jami and jami-bot; one could use as well have e.g. a chat
with doctor or process messages via calc or anything like that. Only
org-jami-bot has a note-taking focus due to the Org mode features being
used.


Thanks and cheers,
Hanno



reply via email to

[Prev in Thread] Current Thread [Next in Thread]