
Each token is one choice from many forking paths. Let's see some of the other possibilities. Also try the Live LLM Token Tree Visualization Tool!
Mostly we talk about LLMs (Large Language Models) as generating one token (roughly a syllable, it depends) at a time. But that's not really the whole picture. Given the context, all of the text that has led up to this point, the model will rank all of the possible tokens and assign each a weight (a probability).
Pair a keyboard with the Norns and Grid. Then you record commands like a set of timed and sequenced macros visible and triggered on the grid. Like a guitar-looper mashed up with a REPL mashed up with a sequencer!

See https://github.com/awwaiid/repl-looper for the code, documentation, and a journal of development.
As both a learning exercise and a fun use of Bracketology, I built a web app to help you pick out a great white elephant gift! I did it initially with Clojure, ClojureScript, Reagent, Figwheel. I've now re-built it with Ruby, Opal, React.rb, and helped build the new opal-hot-reloader!
I'm looking forward to porting to Perl6 once rakudo-js is working :)
After giving a talk on debugging techniques, I started wondering why I (and many others) don't use the debugger in perl much... but generally do use the debugger provided by other systems (firebug). The general idea I came up with isn't that using a step-based debugger is flawed philosophically, as I had initial suspected. Instead I think it is just because it isn't at our fingertips.
This project is an experiment to bring a debugging tool into a popular perl application chain - Plack/PSGI middleware.
Code: git clone http://thelackthereof.org/projects/perl/Plack-Middleware-Scrutiny/.git
START HERE! This page is an overview; much of the music I've written or been involved with in one lovely place. Also check out my Music Gear and Setup!
These works are licensed under a Creative Commons Attribution-ShareAlike (CC BY-SA) License (or maybe CC BY-NC... feel free to ask).
Here are a bunch of songs! Some of these are more proof-of-concept than anything :) . These include both solo efforts and collaborations, follow the links to learn more and maybe get some lyrics, variations, and background.
Ultimately the goal is to digitalize my long-time usage of a Moleskine Pocket Sketchbook. There are several things that can never be digitalized (battery life!), and several advantages that digitalization provides (backups!). I'll use the word "sketch" even though most of the time I'm actually taking notes... the point is that I'm doing handwriting not typing. Here is the gist of it:
I've always wanted some sort of slick web-based wysiwyg-ish graphviz editor. My first step toward that is to convert a graphviz specification file (.dot file) into HTML and javascript. The javascript is mostly for drawing lines.
darcs get http://thelackthereof.org/projects/perl/dot2html
I like to do documentation both directly in a program (like with POD) and in an associated wiki (like here). I do not, however, want to duplicate effort.
This oddmuse module allows me to expose a raw file for display and editing through the wiki interface. Changes to the file will be recorded through Darcs, and after review pulled into the main tree.
Additionally it will have a documentation-only view, displaying only the HTML version of the documentation without the code, just like you were viewing it in perldoc.
I wrote this specifically so that I could use it as a genotype in OGPF. I'm not sure that I ever actually did that... but I'm not dead yet!
It seems to work pretty well, and there might even be some comments in the code. This might be a reasonable example of how to write a lambda calculus parser and interpreter in OCaml.
Get the code at:
This is exactly what it sounds like. I looked around for a solution, but got tired of that quite quickly so just wrote my own. I use a plain textbox and a hidden listbox (SELECT box). When the textbox gets focus the list is displayed right under it, just like a real combo box.
This depends on the lovely behaviour.js library. It is a light dependency -- easily removed probably. But I like it and recommend you use it for other stuff anyway!
See a demo at http://thelackthereof.org/dev/dhtml_combo/combo.html
This extension adds an "Edit" link to sections, so that you can edit them one-by-one. This is to clone the feature in http://www.wikipedia.org/.
For now this depends a bit on the oddmuse plugin (because it uses == ... == as the section identifier, basically). That means that it has to be loaded after oddmuse... hence the 'zzz-' part of the name.
I think maybe this is outdated. You should go over to the continuity website now.
This is a slightly ''different'' approach to web-programming. Here we view a web application a lot more like a command-line driven program. Instead of your program being restarted with each request, we will pretend that your program picks up right where it left off. Here is a small example of a function in this context:
The panel is built around Contize (and eventually Continuity), which gives the whole thing a completely different feel, programming-wise, from other web-based applications. The goal is to remove the obsessive state management from the programmer's tasks and transfer the task back to the language. Instead of the programmer keeping track of the current state in a variable, for example, the current place of execution in the code ''is'' the current state of the program. Since this project was created I started Continuity, so someday the panel will move to use that (and will thus be a little cleaner).
I wrote GrabBag as a datastructure to hold genetically evolving programs (see OGPF). Unlike most collections, this one assumes that when you add an element you don't care where it goes (unordered insertion) and that when you pull out an element you specifically want a uniformly random element.
See the grabbag directory for the source code (GPLed unless you talk to me).
This particular implementation is based on a binary tree which keeps track of how many leaves it has on both its left and right side (the actual data is stored in the leaves). This makes it easy to find the size -- you just add those two numbers from the root of the tree. To grab something at random we take the size (total number of things we have), pick a random number up to that. Then we start at the root... if the number is bigger than the left, we go right and so on until we find the node and pull it out. We make a note of the removal by subtraction on the way back out. 2^n nodes can thus be accessed in 2*n operations (which is equivalent to O(ln n) I believe). Adding works similarly -- we move down the tree finding out where it is lopsided and add the new thingie there, thereby keeping things pretty even.
One of the greatest strengths of OCaml is in data structure manipulation, which is essentially what makes up a genetic programming framework. Thus OCaml is an excellent choice for such an endevor.
The goal of OGPF is to create a modular framework for building genetic programming systems in OCaml. It is additionally an experiment in modular framework design, making heavy use of Functors. OGPF seeks to be a clean, elegant, and efficient solution to the question "How do I do genetic programming in OCaml?"
NOTE: I'm not doing any active work on this project. This project spawned Continuity and that's where I've followed it :)
Contize is a sort of proxy object. You create an instance of your original object, and then give it to Contize. Contize then takes over that object (and you work with the Contize object but pretend it is still the original) and lets the object pretend that it can be suspended and restarted.
There have been quite a few RDBMS->OO Mappers (see http://poop.sourceforge.net/) but none of them have satisfied me. Usually this is because they map on a table-to-object basis, whereas I want something a bit more abstract. Thus was born SetDB. SetDB allows the programmer to view a database in the same way that a database designer would -- as sets of things and relationships between the sets. In general a programmer only sees this world when composing SQL, and from then on sees only a series of rows.
SetDB is a work in progress and the state of the project reflects that fact. Just a warning!
The graph module uses GraphViz to draw graphs. Here are some examples I've put together, but much fancier thinges are possible. See http://www.research.att.com/sw/tools/graphviz/refs.html for GraphViz documentation, and see http://www.research.att.com/sw/tools/graphviz/examples/ for some examples.
<graph abc>
digraph {
a -> b - > c;
}
</graph>
<graph>
digraph {
rankdir=LR;
node [ shape=plaintext fontsize=10 ];
struct1 [
label=<<TABLE border="0" cellborder="1" cellspacing="0" cellpadding="0" width="75">
<TR><TD bgcolor="lightgrey">foo</TD></TR>
<TR><TD>columnx</TD></TR>
<TR><TD>id</TD></TR>
<TR><TD port="barid1">bar_id</TD></TR>
<TR><TD>baz</TD></TR>
</TABLE>
>
];
struct0 [
label=<<TABLE border="0" cellborder="1" cellspacing="0">
<TR><TD bgcolor="lightgrey">bar</TD></TR>
<TR><TD port="barid0">id</TD></TR>
<TR><TD>name</TD></TR>
<TR><TD>date</TD></TR>
</TABLE>
>
];
struct1:barid1 -> struct0:barid0;
}
</graph>
<graph>
digraph {
n1 -> n2;
n2 -> n3;
n3 -> n1;
}
</graph>
<graph>
digraph {
node [shape=box];
rankdir=LR;
n1 -> n2;
n2 -> n3;
n3 -> n1;
}
</graph>
<graph>
digraph G {
subgraph cluster_0 {
style=filled;
color=lightgrey;
node [style=filled,color=white];
a0 -> a1 -> a2 -> a3;
label = "process #1";
}
subgraph cluster_1 {
node [style=filled];
b0 -> b1 -> b2 -> b3;
label = "process #2";
color=blue
}
start -> a0;
start -> b0;
a1 -> b3;
b2 -> a3;
a3 -> a0;
a3 -> end;
b3 -> end;
start [shape=Mdiamond];
end [shape=Msquare];
}
</graph>
This is a horrid thing that you probably shouldn't do. That said -- sometimes it would be nice to evaluate some arbitrary OCaml code at runtime (in Genetic Programming, for example). Based on some code in the interactive toplevel module this isn't hard to do.
The first programming language I ever learned was BASIC on the Apple IIe. It was the best of times... it was the worst of times. I went on to learn lots and lots of other languages, but one of the things that really drew me in to programming was the ease of writing that first little proggie... the magic of being able to get the genie in the bottle to mock things back at me was enthralling.
Later, in High School, there was a wonderful series of programming classes taught by Mrs. Denton (DD as I now get to call her), and she too started her students out with BASIC, albeit a much revised version. I've often contemplated the beginning programmer and how best to introduce them to the art. The answer is unfortunately obvious -- different learners require different introductions. One thing I have decided upon, however, is that there needs to be as little as possible distracting the student from understanding the essence of what they are doing. In teaching mathematics, as an analogy, students are first taught counting, and then addition, and then multiplication. If it were taught the other way around -- with multiplication first and explaining exactly what was going on (the adding and counting stuff) later, then the learning process would be long and quite painful. The same is true of learing to program.
See http://thelackthereof.org/projects/perl/oddmuse_pingback/ for source (and darcs repo).
I would appreciate it if people could link to this page in a pingback-enabled post of some kind so that I can make sure it works. The only way I've tested it is with this client, which has worked swimingly.
This is the first step. Second would be to make oddmuse work as a pingback client too. The trick there is to make sure we aren't over-pinging links and I'm not sure how that should be done.
Vladimir was born out of a few smaller applications needing improvement. The idea is that from the commandline, email, an IM client, or a webbrowser I should be able to access important information. Vladimir will be the conceptual center of all these interfaces -- an information robot keeping track of things for me.
In addition to talking to me, Vladimir will talk to other people too. My ultimate goal is to tell people to "email Vladimir" and set up an appointment with me. Because of this I am investigating natural language interfaces to Vladimir. Natural language is a funny thing -- not nearly as efficient as cryptic short commands, but significantly more user-friendly.