True's beaked whale.jpg

Western spotted skunk

Hooded skunk

Yellow-throated Marten


Archive for the ‘Computers’ Category

An upside for AI / LLMs

Sunday, February 11th, 2024

The new AI / LLM tools have many potential applications, but many of them will have downsides for some people–replacing copy writers, some tech support, these are benefits for the companies that apply them, but many of today’s jobs in those areas will be eliminated.

One application that seems inevitable and all positive is raising the floor for human performance. An tool that you can ask for advice, or better yet an AI tool that monitors you, by email, or watches internet use across devices, and/or is watching on video, understands what the user is doing, understands the context, and provides advice will help people avoid mistakes. While these mistakes are not obvious to the person making them, they are obvious to a person with experience, or able to research the problem. Imagine a person playing chess alone vs. someone playing with a chess program to flag potential mistakes, with the general knowledge of an AI allowing it to work in many more situations.

This AI tool can develop slowly and in a modular fashion, will be useful even in crude form, but will become revolutionary once it gets good enough. Imagine a person using a crude form of this as an interactive chat tool. The person could say, I’m taking a vacation to Greece and get advice on things to do, what they need to know about currency or visas. Or imagine a more advanced AI would remind a person of an appointments, or tells them they need to change the house air filter. If a person was goiing to make a poor decision–routinely using check cashing places or buying a car with poor service record, the AI could warn them.

This AI tool would be able to slot in special modules as needed. A person starting a business could get localized advice on the steps to take. Someone buying a house could get advice on things to check, and a new homeowner could get advice on what to check and repair and reminders for maintenance.

Bruce Schneier’s “AI and Democracy” talk at Capricon 44

Sunday, February 4th, 2024

Bruce Schneier talked at Capricon about fifteen ideas he had on AI that are forming up into a 2024 book. One thing he mentioned is that AI would make lawsuits much cheaper to launch and carry out, and multiplying the number of lawsuits would mean that courts would need to adopt AI adjudication to adapt to this. Bruce passed over this pretty quickly, but I think this will have early and pronounced effect on society.

It looks like legal work is a problem AI will be able to solve soon. That is, AII tools will be able to contribute effectively to the process of filing and carrying out lawsuits. This is not one problem, but a set of related problems that AI will soon be able to do effectively. Given a set of facts and objectives, an AI will be able to determine what type of lawsuit to file, write it up in the proper jargon and format suitable for submission, determine and write a response to opposing counsel motions, summarize and prioritize discovery material, etc. A lot of legal work is routine, repetitive, and very similar to previous cases. Really, a perfect problem for AI.

The immediate upshot is that a lawyer using AI tools will be able to do much more legal work, work faster, and lawsuits will be much cheaper to launch. The short-term impact is that the number of lawsuit filed will go up multiple-fold and this will crash the courts. Gum them up. Bring things to a standstill. US courts are operating at capacity already and can’t handle more cases.

There isn’t any way for courts to prevent this. The lawsuits will be filed by lawyers at established law firms. Lawyers will use AI as a tool, review AI written suggestions and briefs, and from the court’s perspective these lawsuits will look just like the existing lawsuits, there will just be many more of them.

In the long term, it will make sense for judges and the courts to adopt AI tools to accelerate their end of things, but this will require new laws. New laws means years of hearings, discussion, negotiation, etc. Government functions require deliberation and consideration before making big changes. And who will develop AI tools for courts? The market is smaller and more uncertain than the market of making these tools for private law firms. And judges are very conservative, notoriously slow to act, to react, to adopt new technology.

So AI-assisted lawyering will hit the courts at some point in the next few years, but it will take a decade or more for the courts to effectively react.

Limit Firefox memory

Saturday, November 11th, 2023
  1. Open Firefox, go to about:config.
  2. Go to browser.tabs.unloadOnLowMemory, set it to true.
  3. Go to browser.low_commit_space_threshold_mb, set it to 2/3 or 3/4 of total memory on your computer. (e.g. 32GB -> 24000).

Downloading a video from an ebay listing

Wednesday, March 8th, 2023

Using Firefox, go to the item page, open the Firefox Web Developer Tools (Menu -> More tools -> Web Developer Tools). Click on the Network tab in the Tools section, then on the web page click on the video and play it.

In the Network tab, requests for audio_128kb-0.m4s to audio_128kb-16.m4s appeared, and video_720p-0.m4s to video_720p-16.m4s. I copied the URL for the video and audio requests (all the same but with a different -0 to -16 segment), and used wget to download the files. Each was 1-2 MB:


After 32 wget commands, the entire video was present. I downloaded segments from 0 up until after number 16, I got a ‘not found’ message letting me know I had the last segment.

Then I concatenated the pieces together:

cat video_720p-0.m4s >> video_720p.m4s
cat video_720p-1.m4s >> video_720p.m4s
cat video_720p-16.m4s >> video_720p.m4s

And the same for the audio segments. I put the cat commands into a batch file “cat.txt” and ran them using “bash cat.txt”.
Then ffmpeg was used to combine them and convert to mp4 format:

ffmpeg -i video_720p.m4s -i audio_128kb.m4s -c copy ebay_720p.mp4

Using cron to mute sound in Ubuntu 20.04

Wednesday, August 18th, 2021

I wanted to turn off audio at night automatically using cron.

I saw suggestions to use amixer:
export DISPLAY=:0 && /usr/bin/amixer -D pulse sset Master,0 0%
but this gave an error:

ALSA lib pulse.c:242:(pulse_connect) PulseAudio: Unable to connect: Connection refused
amixer: Mixer attach pulse error: Connection refused

This works, add this line to /etc/crontab:

* 23<tab>* * *<tab>jiml<tab>DISPLAY=:0.0 pactl --server unix:/run/user/1000/pulse/native set-sink-mute @DEFAULT_SINK@ true

and restart cron:
service cron restart

jiml is the user with the open desktop.
‘1000’ is the uid of user ‘jiml’, this can be found by:

ls /run/user
id -u jiml

and restart cron:
service cron restart

jiml is the user with the open desktop.
‘1000’ is the uid of user ‘jiml’, this can be found by:

ls /run/user
id -u jiml

Switched to the Cinnamon window manager

Sunday, January 13th, 2013

I run Ubuntu on my main home machine, but the latest 12.04 LTS release has a terrible, barley useable window manager.

I’ve switched to Cinnamon, following the instructions here. Now it all works like it is supposed to.

URL forwarding

Friday, October 1st, 2010

Forwarded my blog from my old server to this one. Added a Rewrite rule to httpd.conf on the old server in the main site <VirtualHost *:80> section:

RewriteEngine On
RewriteRule ^.*/blog(.*)$$1

Postscript site

Friday, August 27th, 2010

Here’s a site with a good Postscript library for drawing variable width lines.

To add a rounded end I added an arc command after the bolt function:
20 setlinewidth
newpath 0 0 moveto
0 -50 200 -150 200 0 rcurveto
reversepath bolt
5 0 179 arc

I used two of these curves to draw a stylized pear.

Free animal pictures

Monday, August 23rd, 2010

Sources of free to use / copyleft animal photos online.
Best–usually has the species name:

Sometimes has the common name, accuracy unknown: Set the creative commons checkbox.

US animals, NPS and FWS images are public domain unless indicated otherwise:

Putting video clips on my blog

Thursday, November 19th, 2009

Putting video clips on my blog was a bit harder than I expected. I first tried converting the .MOV files the camera writes into .avi files using ffmegX and posting them using <embed> tag code. The files showed up great on my Mac but not at all on a Windows computer.

Flash format files, .flv, are the easiest cross-platform way to post video clips. Flash does require that the site supply a Flash player. There are many Flash players available. I tried OS FLV and it worked nicely.

To edit video files I used avidemux, then ffmegX to convert them to .flv, and I put them on the site using the ‘noscript’ <embed> code suggested by OS FLV with the OS FLV player.swf.