Are there other Ruby folks using "distributable dynamic agents" forproject work?



Good Day,

My purpose to write this is to possibly discuss with people if
somebody thinks they understand the nature my project. I am
independent of any businesses or institutions. All the work is 100%
in 1.9.1 Ruby now and not so big or overwhelming on the
Serverside. Just teaching myself anything on the clientside and get
giant headaches and frustration at all things JS.

Here is a basic project descriptions:

Project is ongoing and was started with a Berlin Internet company
about 5 years ago. He was to do the clientside. Then he move to
This project uses extensive "Helper Library" system (maybe like
HelperLibrary allows the 'agents" to be simple.
There are two types of "Agents": 1. Data 2. Rule (data simple,
rules make assertions, some overlogic but all like natural language
The agents are multi-sections. Each "section" is actually a DSL.
data have 2-3 sections rule agents have 6-7 sections
The "Engine" can "fire" over 2,500 "agents" per second on my less than
1/2 state-of-the-art machine. (Execution of one DSL / but they can
"early out")
Agents leave "casings" (dont ask) - but this is a record of all
interface actions with the HelperLibrary.
My background is much manufacturing/process contrl / statistical so
maybe you can guess how "casings" will contain useful back-chaining(?)
type information.
Agents are text files, maybe to think of as a EMail? But from
computer to computer so no chit chat, but reads much like a natural
Data is stored in what I call a "Object Server" like a "automatic
database" but a "Object" IS the record. This way a method becomes a
"Topic". Maybe think of a a 3d database, not sure but very flexible
for my own work, performance, and run-time dynamic 'vocabulary'
building is all now is full automatic.
After Object servers established in a Domain (1st domain have 5
servers) then work project work seems mostly to be done in the
HelperLibrary - nothing else to

What maybe interesting if you follow above some - is that the Agents
created in a "Expert Session" which is like filling in a form to
create sentences.
This means that the "agents" can be created by anybody, anytime per
the web to build knowledge in the ObjectServers.

This project has been on and on going, progress is slow now because I
am working alone on much of it and know very little, and have no real
for to build internet interface, although some critical screens have
been modeled in Tk on Ruby - great frustration at first - but now done

Please understand that I am an applications programmer some of old-
school but some of new and I do have a 'git' account but find it
awkward and can't
believe all the fuss and invented language to do somethings simple. I
also have no time for "is it bigger than a bread-box?" dialogs. If
somebody knows of
anything like this then please let me know, but so far searches have
not found anything.

Finally, I will be interested to contribute the code to some entity
that know / and have a record of doing this right, but until I finish
the project, so far, I cannot
see anything but grief come from sharing without documentation and
proper support.




Ryan Davis

If somebody knows of anything like this then please let me know, but =
so far searches have not found anything.

I believe Arthur Murray's Mind project is a very similar project to =
yours. I even saw his book last time I was at my university bookstore.


One part of the concept as I am working with it is to have the "Class
Server" (data holding methods are static) build a
"Vocabulary" of all the Keywords used in all current units of what is
simple Ruby Hash. By convention the information is
built in a structurally not very complex way - here is a small part of
this from the work:

def Acorus_calamus.parts_used_#02
at = "Dried rhizome"
[{:SATZEN=>[ac], :SOURCE=>[at], :REF=>1}]

def Acorus_calamus.general_#03
image = "
at1= "Calamus, or Sweet Flag, combines demulcent effects
of the mucilage with the carminative effect of the volatile oil and
the stimulating effect of the bitters."
at2, at3 = "", ""
ac1 =
ac2 =
ac3 =

bt= "It is thus an excellent tonic for the whole gastro-
intestinal tract."

ct= "It may be used in dyspepsia of all kinds, in
gastritis and gastric ulcers."

dt= "It will stimulate a flagging appetite and help to
ease exhaustion and weakness when there is a digestive involvement."

et= "It may be considered a specific in colic resulting
from flatulence."

[{:REF=>1, :SOURCE=>[at1, at2, at3, bt, ct, dt,
et], :SATZEN=>[ac1, ac2, ac3, bc, cc, dc, ec]}]


The "Vocabulary" built has 3 levels that must be "Ajaxed" on the
client side - and this enables a front-end that uses
simple 3 columns to build small sentence parts by doing no more than
picking from relatively short lists. Clearly the
percent of "new" keywords decreases as the use of the system goes on
and the "vocabulary" is extended to cover more and
more cases. Not "Rocket Science" is only common sense.

Yes, there is an existing Tk based interface to do this that has been
working now for months. Result of this is that a simple "Data Agent"
is built and "sent" to the ServerSide - these are the small script

I am glad to share also example Agent files of both types.


Skip now to some "advantages" that we see some of us. No big working
system yet. Simple - this is conjecture - but all pieces have been
built and tested but across several domains in 5 years as changes made
to what experience is teaching.

It is rather like there are "no moving pieces" - no deep logic - only
many little units of (in our case) outside contributed information
(data) and outside contributed assertion "system" (not big deal - but
multiple assertions) which is the 'rule' side.

Then you have a "swarm sender" class and a "swarm reader" class both

The "Helper System" is where most of the work is done. Favorite
example of power here is that all "Units" from universe is converted
to One Unit system (metric) and all calculations and downstream work
is then so much simpler. So he Helper Library is where in set up
system an increasing amount of the work is done.

One thing maybe clear from this - that if all units are set up to be
handled in one domain - then is available for all other domains so
there is a nice way for a bigger system to get built up layer on

Ruby has made all of this doable and really pretty to the eyes of this
old-school programmer having fun.

If somebody would like to see example agents will be glad to provide.

Thank you!


I think just now a "example vocabulary" - that is built automatically
might be interesting for somebody that is trying to
follow all this:


1). names_primary
2). parts_used
3). general
7). preparation_and_dosage
8). collection
9). caution
10). images
4). [:REFSET, {:KEY=>[:REFSET]}]
2). [:HERB, {:KEY=>[:FORM, :pART]}]
3). [:INFO, {:KEY=>[:NOTE]}]
4). [:pREPARATION, {:KEY=>[:FORM]}]
5). [:REFSET, {:KEY=>[:REFSET]}]
1). [:GROUP,
5). [:HERB, {:KEY=>[:pART]}]
6). [:INFO, {:KEY=>[:NOTE]}]
10). [:REFSET, {:KEY=>[:REFSET]}]
2). [:ACTION, {:KEY=>[:ACTION]}]
3). [:BODY, {:KEY=>[:SYSTEM]}]
4). [:REFSET, {:KEY=>[:REFSET]}]
1). [:GROUP,
3). [:HERB, {:KEY=>[:UNIT]}]
4). [:pATIENT, {:KEY=>[:STATE]}]
6). [:pREPARING,
7). [:REFSET, {:KEY=>[:REFSET]}]
3). [:HERB, {:KEY=>[:pART]}]
4). [:INFO, {:KEY=>[:NOTE]}]
5). [:REFSET, {:KEY=>[:REFSET]}]
1). [:GROUP, [:INFO, :REFSET]]
2). [:INFO, {:KEY=>[:CAUTION]}]
3). [:REFSET, {:KEY=>[:REFSET]}]
1). [:GROUP, [:REFSET]]
2). [:REFSET, {:KEY=>[:REFSET]}]


This is automatically extracted/re-extracted from the data in this
"Class Server"

So 1st colum is the Method
then the "Key Base Word
then the Key_2nd part

experimented with more levels but this works out as pragmatic "medium"
and seems like clear best.


Result is that by selecting from only 3 columns that a client can
build sentences in a natural like language (picking only most of
time. There is a "Seed" system now - so no need to start from

There is a built in ability to translate from "Techlish" (technical
english) from the internal format. This avoids And/Or normal
ambiguities. And (not played with much yet) there seems to be a nice
way to translate to multiple natural languages that just falls out.

One more note from experience: there is a GROUP+KEY of INFO_META
which supports an interesting direct "client to computer possibility)
as well as a INFO_TEXT keyword that supports person to person

Thank you





When I visited here the first time I was very excited to have the
first "agents" executing. I used the term "Boid"
which carries some "heavy AI baggage". This "offended" here some
people, and for that I am sorry.

My project is written in 100%, nice and shiny, is also not too much
more than maybe 2,000 lines so not really very complex (this is the
Server-side only). Other than client-server work (one library:
EventMachine) there are no dependencies.

But since there is so much earnest interest here :) let me tell a
little of the story on how this project started. I am retired now
(3rd time) and have more time...

As somebody that has been loving to program for over 30 years I have
used the "trick" of DSLs (now called) many times in many ways to amaze
various employers (before I knew what it was called). So about 4 1/2
years ago, I was using my trick to build a DSL to do something but the
language kept getting more and more complex (unit conversions a
So I do what I do and how I do it and one morning after breaking head
on this I ask "what if instead of big complex DSL" I break this down
somehow into smaller simpler ones (a goal of this system is that
anybody can contribute rules or data from browser). Well this lead to
using many small DSL pieces - and setting everything up so the
building of the agent can be kept also very simple (it follows). Now
all the complexities and nastiness of common things like "unit
conversions" is removed to one organized place - to the helper Library
(like Ruleby uses).

Now things just became much more fun! There were "system" waves of
these program units to set things up (not from clients) and many
things evolved in a very natural common sense way - just also very

There are some 9 Functions (large classes or modules) in this system
as currently structured. Each one is now pretty
simple. The most distinguishing feature of this system is, I believe
is the use of many small program parts. The advantages of this are
clear to me after working on this but not so simple to explain.

Above, in my messages I cut real snippets from real operating code. I
offer to make an interesting bet with anybody about any of it that it
isn't real code that works with Ruby 1.9.1 interpreter. Here are the
major functions:

1. "Class Server" which logically enough serves classes that have
static methods. Also builds a vocabulary from all
GroupKeyWords + all Keywords + all data items ever assigned. Does
simple things like giving a list of commands and
such for obvious "handshake" purposes.

2. There is a Agent Launcher

3. There is a HelperLibrary which agent makes a "visit" to each
"flight" - this is were the work is done - the agent "sends message"
and gets responses - no brains in the agent as said - near pure data
or near pure rules.

4. There is a Agent Reader

5. There is a WhiteBoard System - have contributed this already - MF
helped me with the "method come from" code.

6. Don't forget the body of Agents - they are simple text files with
multiple DSL / subsections

7. There are records of all variable (success, value, exceptions...)
"transactions" with the overall result of assertons (pass / fail) and
not too difficult to understand

8. There will be a "control panel" that allow drill down into the
nitty griddies of the sets of assertions that all went toward arriving
at a single (maybe) shiney conclusion (like a best fit product, or a
compatibility issue, or a possible inter-action of two drugs... in
short the problems being solved)

9. Client Side (in future) interface units to allow "experts" to
contribute Data or Rules (by way of causing an agent to be built)


There are is no free lunch. First - Data must be loaded into a
strict format - see above somewhere another posting - but it is also
very very flexible as you are more or less "talking to the computer"
in a natural like language - hope this doesn't offend anybody here -
but is true! I have screen captures of the working system if you
don't believe me.

Second - somebody somewhere sometime must contribute the rules. This
is what is, perhaps, so interesting! Your clients, people in field,
authors, your aunt jill, or anybody with a enabled cell phone / or
laptop, or tablet, or even a desktop can contribute - he or she - is
doing something he or she has been doing since age 3 or so - he or she
is building sentences.

Thank you,