On Sun, Dec 22, 2024 at 04:49:50AM +0700, Ignat Insarov wrote:
> I am glad to hear that you are enthusiastic about improving the
> documentation. Tell me if there is anything specific I can help with.
>
> As a first step, I can offer a general suggestion. Surely you have a
> family member or a friend who is digitally literate but not familiar
> with Common Lisp and FriCAS. Ask them to set up a FriCAS Jupyter
> notebook and watch. Will they even be able to find the installation
> guide? It is not linked to from the table of contents! This method is
> called «usability testing» and you can find more details, for example,
> in the book _About Face 3_, chapter 4.
Well, for me this is not a workable proposal: FriCAS is really
for people interested in/needing mathematics, and my family have
no such interest. OTOH some of my fellow mathematicians installed
FriCAS. I admit, I have created hsbcl-1.3.9.tar, but I did not
intall Jupyter myself (Jupyter needs _a lot_ of system componets
and on my old system it would be too much trouble to install
them. I have now new system which I am still setting up and
eventually I will install Jupyter).
> Overall, this problem calls for two items of documentation: a guide
> and an explanation.
>
> * The guide would be a list of steps that can be performed with
> minimal research. The three commands listed right now are clearly not
> enough. Whence do I get this `hsbcl-1.3.9.tar`?
In FriCAS distribution area:
https://sourceforge.net/projects/fricas/files/fricas/1.3.9/hsbcl-1.3.9.tar
(the first Google hit for hsbcl-1.3.9.tar). Or corresponding area
on Github.
It may be confusing that this tarball is in subdriectory for
release 1.3.9, but this code did not change between FriCAS
releases.
> How do I check if all
> the steps succeeded — what should happen?
Instruction says:
... creates executable binary "hsbcl" ...
You should see new binary called "hsbcl".
> At what point in the build
> process do I run these commands,
Before rest of FriCAS build. After part about creating "hsbcl"
instruction says:
After creating "hsbcl" one can then configure FriCAS like
...
I assumed (maybe wrongly) that textual order and the word "After"
in fragment above should make clear order of steps.
>in what folder?
That is your choice, any should work.
> This is also where
> you can mention Quicklisp if it is helpful, or not mention Quicklisp
> if it is not helpful.
In instruction above mentioning Quicklisp is probably not helpful:
the point of "hsbcl-1.3.9.tar" is that you get all extras that must
be present in FriCAS binares as one package. In particular,
Quicklisp is not needed. Quicklisp may be useful for people
that already use it, in particular to Lisp programmers.
> Usability testing will help you figure out the
> best way.
>
> * The explanation would define all the terms and give links where
> appropriate. It would put everything in perspective. Maybe it would
> say that FriCAS is based on Common Lisp and it needs to be built with
> a specially prepared Common Lisp executable that has a web server
> baked in.
Instruction says:
The jFriCAS interface needs a web server built into FRICASsys binary.
This can be done by using Lisp (currently only SBCL) containing
the Hunchentoot web server.
So it essentially says what you suggest, except for, it does not
use word "based" (which could be easily misunderstood) or
"baked in" (which is quite fuzzy). It gives you all keywords
to find more info if desirable.
You should be able to build FriCAS with Jupyter interface without
understanding paragraph above. Similarly, you should be able
build and use FriCAS without knowing what Lisp is. In fact,
you should be able to contribute to FriCAS developement without
knowing what Lisp is.
> You should also explain what a «FriCAS distribution area» is
Well, Sourceforge and Github provide per project areas to distribute
releases, both source and binaries. «FriCAS distribution area»
is such an area for FriCAS. In release 1.3.9 this should have
been obvious, as hsbcl-1.3.9.tar is in the same directory
as fricas-1.3.9-full.tar.bz2 (that is source tarball).
Now we probably should give a link.
> Thank you for this detailed example. I read the page you linked to
> earlier today in the course of my research, but I was intimidated by
> the need to edit the source code so I gave up. I see now there are
> friendly comments in there — this is nice.
>
> * I am not sure about `nosman` since it seems to also disable graphs,
> and I do want graphs.
>
> * I think this is a situation that calls for a configuration file. I
> do not believe editing the source code should be the preferred way of
> configuration, at least for the following two reasons:
>
> - If `jfricas` is installed via a package manager, such a
> modification would be erased when it is updated.
Well, when using package manager there is always question who
is in charge: package manager or a user. Modern approach
is to put user modifications in separate files which are
used from files provided by package. It makes little difference
it this is source code or configuration file. Rather, the
point is that information is in multiple files with differing
"authority" over files: some are "user" files, some possibly
for other packages, some maybe for system administrator,
some coming from base source. Linux distributions have
various policies with respect to such files, so I am not
sure what we (that is FriCAS project) should do. 'jfricas'
currently is not packaged, so this is not an issue.
> - Many people will find this task intimidating.
Using FriCAS is essentially writing source code in FriCAS
language (maybe line by line, but still). I hope that
people are not intimidated by this.
> How FriCAS and jFriCAS should be configured is of course an
> architectural decision that requires deep understanding of the code
> and the use cases that need to be handled, so I cannot be of much help
> here. If I may suggest something, I should say there should be one
> place where everything may be configured. Right now there are at least
> four places — build configuration, command line flags, Python source
> code and the start-up profile file. This complexity seems needless to
> me.
Part of this is thechnical neccesity (or maybe technical simplicity):
build configuration specifies info needed to compile FriCAS and some
hardcoded defaults. It is not possible to do this later: without
proper info build may fail and hardcoded things can not be changed
later. Command line flags are easily changable things which users
may wish to change. For technical reasons FriCAS user init file can
not be run very early, so it can not change some things which are
changable on command line.
You skipped enviroment variables: they affect what FriCAS is
doing. Build configuration, command line options, enviroment
variables and init file are normal mechanisms used by many
other programs. In FriCAS some small important parts are source
code, so changing them allows users to do changes that would
be hard otherwise. Certainly, we aim that commonly requested
changes of behaviour could be done by one of earlier mechanisms.
But modifying source fragments is useful way to do unexpected
modifications.
--
Waldek Hebisch