Monday, March 31, 2008

I agree with Stallman and all my software is "free" software

http://itmanagement.earthweb.com/osrc/article.php/3737586

I don't know why I have "never" wanted to write "commercial" software on my own. All of my software that I have created has been "free" software. It almost seems innate that software should thrive that way.

"Stallman: No. I’m just insisting on freedom for computer users. Although I sympathize with a programmer’s wish to make more money, that is not as important as respecting other people’s freedom. In fact, developing a non-free program is an attack on society, and I hope that you will not be able to do it."

I completely agree with Richard Stallman on this.

Thursday, March 27, 2008

ANN: google-code project releases (haskell, erlang, jvm source and more)

I finally had a chance to review my projects on google code and setup downloadable releases: Here are the projects descriptions and downloads:

http://code.google.com/p/haskellnotebook/

The Haskell Notebook (another Haskell Cookbook) contains some common and not so common Haskell programming idioms that are contained in a collection of working/compilable examples. There is also a collection of source code from other functional programming languages including Lisp and Erlang. This project is similar to other cookbook projects that you may find on the web for various other programming languages.

Compiling the Source

If you are attempting to compile the source, you should be able to do the following assuming that you have the Glasgow Haskell Compiler installed. In the event that you copied the code from one of the wiki pages and you receive an error, check the subversion repository or downloads for a mirror of the wiki example (the formatting on the wiki may have caused the issue).

ghc --make -fglasgow-exts Simple.hs

Functional Programming and Factor

This notebook and set of cookbook examples was ideally setup to explore different functional programming languages. Even though Factor is not considered to be a functional programming language. It is still an interesting project and language, so some factor cookbook examples will also show up under this project.

Resources

Milestone and CHANGELOG highlights

Haskell/Erlang examples set1 (3/28/2008)

  • uploaded HaskellSimpleTextMining?.tar.gz - haskell text mining example; covers many different aspect of haskell. Including a web scraper (python) and tools to analysis web document, naive bayes analysis, finding simple document statistics.
  • uploaded SimpleIrcClient_Erlang?.tar.gz - simple erlang IRC client
  • uploaded erlang_set1_d032008.tar.gz - erlang cookbook examples set1
  • uploaded haskell_set1_d032008.tar.gz - haskell cookbook examples set1, many topics include monads, cabal, reading/writing binary files, etc
  • uploaded lisp_set1_d032008.tar.gz - lisp cookbook examples set1, lisp widget toolkit (example FFI source code), lisp apache log file analysis tool


http://code.google.com/p/jvmnotebook/

The Java Virtual Machine ( Sun's JVM is called HotSpot ) is a java bytecode intepreter which is fast, portable and secure. Jython, JRuby, Scala, ABCL (Common Lisp) are popular language implementations that run on the JVM that allow for the jvmcookbook sugar of their particular languages.

This project contains multiple sub-projects and code demos related to those jvm language implementations.

Milestone and CHANGELOG highlights

JVM Notebook, set1 release (3/27/2008)



http://code.google.com/p/octaneos/

Also, octanemech

http://code.google.com/p/octanemech/

Sunday, March 23, 2008

The FBI has gone too far

http://arstechnica.com/news.ars/post/20080323-rick-rolled-to-child-porn-youre-a-pedophile-says-fbi.html

Everyone has had it happen to them: a "friend" sends you a link in IM or over IRC that purports to be something like a cat in an awkward position with a hilarious caption. Soon, however, you discover that the link wasn't to a lolcat at all; instead, you've been Rick Rolled—or even worse, sent to 2girls1cup (find it on your own, but be warned: it may scar you for life). These pranks are commonplace now, but be careful of what you click on and from whom. If that link points to anything even pretending to be child porn, that's enough evidence for the FBI of intent to download it. The authorities could then raid your home and possibly throw you in jail.

Saturday, March 22, 2008

Domain name change: ghostbots.com

http://www.ghostbots.com/botlist/

botspiritcompany.com is still active, but I will be using ghostbots.com

Wednesday, March 19, 2008

glAnts revived in screen capture video

I was able to actually play glAnts. I played it in Wine under linux. It rant at 300 fps. The windows-windows version ran at 30fps. I didn't run the newer "linux" source. I compiled but it didn't run.

Well, here is the video if you are interested.

glAnts project
http://glants.sourceforge.net/

A description of the demo and other older code from my 2000-2003 years.

http://www.botnode.com/src/before/

Descr:
http://www.botnode.com/src/before/home.html

The video, 20MB of my little game. The 2D one was better.

http://www.botnode.com/src/before/glants_bot_berlin.avi

Tuesday, March 18, 2008

My top 35 anime review list as an Amazon List

Enjoy. I have been wanting to compile this list for a while. This list will keep you busy for a couple of months or so. I still have about 40-50 more I can add to the set.

http://www.amazon.com/Complete-nbsp-Anime-nbsp-Collection/lm/R3I0KAPNL5CTIZ/ref=cm_srch_res_rpli_alt_1

Monday, March 17, 2008

Working on my thesis

Details pending. But I am working on my thesis.

ANN: botlist - added foaf application/repository on botlist

Now you can store profiles. Eventually the crawler will index the "friends" on a particular profile.

http://botspiritcompany.com/botlist/spring/semantic/foaf/foaf.html

Sunday, March 16, 2008

Good research site Cogsci

http://www.cogsci.rpi.edu/research/rair/projects.php

Thoughts on Artificial Intelligence

The computer science field of Artificial Intelligence has sparked a lot of interest yet hasn't really turned up many visible products. There are a lot of projects out there and I don't want to even attempt to minimize the amount of effort that has been spent on AI research, but by and large there aren't many visible "AI" companies or tools that we use regularly.

A large part of that has to do with the confusion of what AI is? What does artificial "intelligence" mean? I know about programming language research. The goal there is to create expressive, productive programming languages. Systems research centers around operating systems, distributed systems, fault tolerance and other similar areas. But AI could mean different things to different people.

Change the Vocabulary


My suggestion is to do away with the term AI all together. It is not useful, even at a high-level. Modern software is pretty "intelligent". That is the goal of most software. We humans need a way to communicate with software in order to tell the software to do something. The software will respond with a set of terminology or actions that we understand. A lot of software is good at that. If I tell google to give me information on cars Google will return a set of listings on cars. I don't know the internal details, how it came up with the information. All I do know, I am normally happy with the results. The back and forth conversation with google was a positive one. Google is an AI. Microsoft windows/Ubuntu Linux are forms of AI? The seem pretty intelligent to me.

So the term AI doesn't mean a whole lot. Or at the very least, it is a misnomer. I am not totally set of this term, but it seems to fit for the time-being. "evolved, adaptive artificial systems". That is what we are looking for. Systems that have evolved past the "dumb" systems that we are normally used to. Outside of google, most applications are built with every action, feature is known. If a piece of software does something that we don't expect, we call that a bug. An evolved system is one that is adaptive to its inputs. You may not get the same output if given a known input. The term evolved is less meaningful than adaptive. In 100 years, the software will have evolved past what it is today. I want to use the term because of the connection with typical usage of evolution. A dumb amoeba is the basis of all life. Man is the result of millions of years of evolution. The software of tomorrow will evolve past the software of today.

The question is, what determines that evolution? What will google look like in 100-200 years. What processes will encourage evolution. Does open source encourage? Does the addition of AI technology encourage it. Will the future evolved software thrive on autonomous, fault tolerant operations?

Saturday, March 15, 2008

Botlist files and directory structure

I actually cleaned and removed some content from this file. But here is a list of all the files in the botlist J2EE web frontend. There is a still a whole project in the 'botlistprojects' that includes source for the backend.

Here is a cleaner version of this file.

http://openbotlist.googlecode.com/svn/trunk/openbotlist/docs/FILES_AND_DIRECTORY_TREE



|-- LICENSE.BOTLIST - Updated botlist license file
|-- LICENSE.TOMCAT - Tomcat license file (deprecated)
|-- README.txt - Quick start file and description of botlist project
|-- WEB-INF - J2EE web-inf configuration
| |-- applicationContext-acegi-security.xml - acegi spring configuration
| |-- botlist_config.properties - main database password spring settings and other path settings
| |-- botlistings-servlet.xml - main spring configuration for botlist
| |-- botlistutil.tld
| |-- classes
| | |-- Botlist.hbm.xml - Main botlist hibernate configuration, bean definitions, etc
| | |-- ehcache.xml - ehcache configuration
| | |-- hibernate.cfg.xml - hibernate configuration (includes Botlist.hbm.xml)
| | |-- hibernate.properties - other misc hibernate settings
| | |-- log4j.properties - Botlist web application logging configuration
| | |-- messages.properties
| | `-- version.properties
| |-- example_botlist_config.properties
| |-- jsps
| | |-- INIT.jsp
| | |-- INIT.rb
| | |-- ajax
| | | |-- vote.jsp - jsp file for up / down voting ajax code
| | | `-- vote.rb -
| | |-- botlistadmin
| | | |-- accessDenied.jsp
| | | |-- acegilogin.jsp
| | | |-- home.jsp
| | | `-- secure
| | | |-- extreme
| | | | |-- docwrite
| | | | | |-- confirm.jsp
| | | | | `-- index.jsp
| | | | `-- index.jsp
| | | `-- index.jsp
| | |-- bots
| | |-- botverse
| | | |-- botverse.jsp - Main botverse view jsp link page, see /botlist/spring/botverse/botverse.html
| | | |-- botverse.rb - Controller and business logic for the botvere view page
| | | |-- botverse_confirm.jsp
| | | |-- botverse_submit.jsp - Allow users to submit user links
| | | |-- botverse_submit.rb
| | | |-- calendar
| | | | |-- botverse_calendar.jsp
| | | | `-- botverse_calendar.rb
| | | |-- group
| | | |-- linkaddcomment.jsp
| | | |-- linkaddcomment.rb
| | | |-- linkaddcomment_confirm.jsp
| | | |-- linkviewcomments.jsp
| | | |-- linkviewcomments.rb
| | | |-- rover - Remote/Peer api, library for remote clients to using a set of REST calls to submit new links
| | | | |-- botverse_rover.jsp
| | | | |-- botverse_rover.rb
| | | | |-- forum_rover.jsp
| | | | |-- forum_rover.rb
| | | | `-- rover_confirm.jsp
| | | |-- rss
| | | | |-- botverse_rss.jsp
| | | | `-- botverse_rss.rb
| | | `-- text
| | | |-- botverse_light.jsp
| | | |-- botverse_light.rb
| | | |-- botverse_text.jsp
| | | `-- botverse_text.rb
| | |-- chart
| | | `-- daily_chart.rb
| | |-- citylist.jsp
| | |-- citylist.rb
| | |-- contactemail.jsp
| | |-- contactemail.rb
| | |-- contactlisting.jsp
| | |-- contactlisting.rb
| | |-- create_listing.jsp
| | |-- create_listing.rb
| | |-- createconfirm.jsp
| | |-- default_footer.jsp
| | |-- errorInvalidView.jsp
| | |-- forums
| | | |-- comments
| | | | |-- topics.jsp
| | | | `-- topics.rb
| | | |-- forumaddtopic.jsp
| | | |-- forumaddtopic.rb
| | | |-- forumaddtopic_confirm.jsp
| | | |-- forums.jsp
| | | |-- forums.rb
| | | |-- forumviewtopic.jsp
| | | |-- forumviewtopic.rb
| | | |-- viewforums.jsp
| | | `-- viewforums.rb
| | |-- general - Partial include jsp files
| | | |-- botverse_calendar.jsp
| | | |-- botverse_incl
| | | | |-- botverse_default_meta.jsp
| | | | |-- botverse_index_sect.jsp
| | | | `-- botverse_index_sect_right.jsp
| | | |-- botverse_link_css.jsp
| | | |-- botverse_link_stat.jsp
| | | |-- botverse_navigation.jsp
| | | |-- botverse_profile_nav.jsp
| | | |-- command_profile_nav.jsp
| | | |-- default_doc_type.jsp
| | | |-- default_footer.jsp
| | | |-- default_includes.jsp
| | | |-- default_navigation.jsp
| | | |-- default_profile_nav.jsp
| | | |-- foaf_quick_navigation.jsp
| | | `-- forreg_profile_nav.jsp
| | |-- help
| | | |-- about.jsp
| | | |-- about.rb
| | | |-- contact.jsp
| | | |-- contact.rb
| | | |-- help.jsp
| | | |-- help.rb
| | | |-- source.jsp
| | | `-- source.rb
| | |-- include.jsp
| | |-- index.jsp
| | |-- invalid_page.jsp
| | |-- listings.jsp
| | |-- listings.rb
| | |-- mocktestslist
| | | |-- mocktest_listings.jsp
| | | |-- mocktest_listings.rb
| | | |-- mocktest_sections.jsp
| | | `-- mocktest_sections.rb
| | |-- newadmin
| | | |-- admin_confirm.jsp
| | | |-- botverse_editheadline.jsp
| | | |-- botverse_editheadline.rb
| | | `-- home.jsp
| | |-- pipes - Library for the developer api that can access botlist data
| | | |-- botverse_pipes.jsp
| | | |-- botverse_pipes.rb
| | | |-- global_pipes.jsp
| | | |-- global_pipes.rb
| | | |-- pipes.jsp
| | | |-- rdf.jsp
| | | |-- rdf_nutch.jsp
| | | |-- remotesync.jsp
| | | |-- remotesync.rb
| | | |-- remotesync_send.jsp
| | | |-- remotesync_send.rb
| | | |-- search_pipes.jsp
| | | |-- search_pipes.rb
| | | `-- sync_confirm.jsp
| | |-- profile
| | | |-- login.jsp
| | | |-- login.rb
| | | |-- loginconfirm.jsp
| | | |-- loginconfirm.rb
| | | |-- logout.jsp
| | | |-- logout.rb
| | | |-- overview.jsp
| | | |-- overview.rb
| | | |-- register.jsp
| | | |-- register.rb
| | | |-- registerconfirm.jsp
| | | |-- registerconfirm.rb
| | | |-- settings.jsp
| | | `-- settings.rb
| | |-- rss
| | | |-- listings_rss.jsp
| | | `-- listings_rss.rb
| | |-- search
| | | |-- addtopics.jsp
| | | |-- addtopics.rb
| | | |-- global.jsp
| | | |-- global_results.jsp
| | | |-- global_search.jsp
| | | |-- global_search.rb
| | | |-- invalidsearch.jsp
| | | |-- results.jsp
| | | |-- search.jsp
| | | |-- search.rb
| | | `-- text
| | | |-- search_textview.jsp
| | | `-- search_textview.rb
| | |-- sections.jsp
| | |-- sections.rb
| | |-- semantic
| | | `-- foaf
| | | |-- foaf.jsp
| | | `-- foaf.rb
| | |-- stats.jsp
| | |-- stats.rb
| | |-- viewlisting.jsp
| | `-- viewlisting.rb
| |-- lib - java and ruby libraries. Mostly jar files.
| | |-- README_FILES.txt
| | |-- acegi-security-1.0.6.jar
| | |-- ant-antlr.jar
| | |-- antlr-2.7.6.jar
| | |-- antlr-2.7.7.jar
| | |-- antlr-3.0.1.jar
| | |-- antlr-runtime-3.0.1.jar
| | |-- asm-2.2.3.jar
| | |-- asm-commons-2.2.3.jar
| | |-- backport-util-concurrent.jar
| | |-- bsf.jar
| | |-- c3p0-0.9.1.2.jar
| | |-- cglib-nodep-2.1_3.jar
| | |-- commons-codec.jar
| | |-- commons-collections.jar
| | |-- commons-dbcp.jar
| | |-- commons-fileupload.jar
| | |-- commons-io.jar
| | |-- commons-logging.jar
| | |-- commons-pool.jar
| | |-- commons-validator.jar
| | |-- dom4j-1.6.1.jar
| | |-- ehcache-1.3.0.jar
| | |-- emma.jar
| | |-- emma_ant.jar
| | |-- hibernate-annotations.jar
| | |-- hibernate-commons-annotations.jar
| | |-- hibernate-entitymanager.jar
| | |-- hibernate3.jar
| | |-- jakarta-oro-2.0.8.jar
| | |-- jarjar-0.7.jar
| | |-- jarjar.jar
| | |-- jcommon-1.0.9.jar
| | |-- jfreechart-1.0.5.jar
| | |-- jline-0.9.91.jar
| | |-- jruby-openssl.jar
| | |-- jruby.jar
| | |-- jstl.jar
| | |-- jta.jar
| | |-- junit.jar
| | |-- lift-core-0.6.jar
| | |-- log4j-1.2.14.jar
| | |-- lucene-core-2.1.0.jar
| | |-- mysql-connector-java-5.0.8-bin.jar
| | |-- plaincharset.jar
| | |-- ruby
| | | |-- actions
| | | | |-- core_users.rb
| | | | `-- group_links.rb
| | | |-- rspec
| | | |-- util
| | | | |-- botlist_core.rb
| | | | `-- chart_graphics.rb
| | | `-- web
| | | |-- entity_links.rb
| | | |-- users.rb
| | | `-- web_core.rb
| | |-- scala-library-2.7.0.jar
| | |-- spring-beans.jar
| | |-- spring-core.jar
| | |-- spring-jdbc.jar
| | |-- spring-test.jar
| | |-- spring-web.jar
| | |-- spring-webmvc.jar
| | |-- spring.jar
| | |-- sqlitejdbc-v037-nested.jar
| | |-- standard.jar
| | |-- stringtemplate-3.1b1.jar
| | |-- taglibs-datetime.jar
| | |-- taglibs-request.jar
| | `-- taglibs-string.jar

...
...
...

Tuesday, March 11, 2008

ANN: botlist - core libraries all updated

The core libraries for botlist have been updated:

Upgraded to:

- Spring 2.5.2 (http://www.springframework.org/)
- Hibernate 3.2.6 (http://www.hibernate.org)
- ANTLR 2.7.6 (http://www.antlr.org)
- JRuby 1.0.3 (http://jruby.codehaus.org/)

Saturday, March 8, 2008

Yet another simple server in erlang, also a look at use of eunit test framework



The diagram above depicts my simple architecture for an Erlang server and library that responds to various client character requests. You should already be familiar with some of Erlang's advantages and know that the strength of Erlang is its lightweight parallel process/thread management and network programming. Not to mention, it is not a bad easy to learn, general purpose functional programming language.

Starting the server:


The following set of instructions are used to start the server and two processes are created. The first is a simple one that waits for incoming requests from the server middleware piece.

%% Simple functional test for the server library
simple_server_lib() ->
io:format("starting server <with server library support>~n"),
AppHandler = start(),
io:format("trace: top-level app handler~p~n", [AppHandler]),
Client = #irc_server_info{app_handler=AppHandler},
ServStart = server_lib:start_link(Client),
case ServStart of
{ ok, P } ->
io:format("trace: app:server pid/lib [~p]~n", [P]),
server_lib:server_listen(P),
State = server_lib:get_cur_state(P),
io:format("trace: state [~p]~n", [State]),
server_handler(#serv_handler_info{lib_handler=P}, idle)
end.


The simple wait for messages process



wait_for_messages(idle) ->
io:format("trace: app:waiting for messages~n"),
receive
{ connection_closed } ->
io:format("trace: app: client connection closed~n");
{ shutdown } ->
io:format("trace: app: shutting down server.~n"),
% Exit point for the application, full shutdown.
erlang:halt();
Else ->
io:format("trace: app: invalid message~n")
end.

The server library



handle_call(irc_server_bind, _From,
#server_state{client=Client } = State) ->
Port = Client#irc_server_info.port,
io:format("trace: lib:handle_call:bind Port:<~p>~n", [Port]),
{ok, ServSock} = server_bind(Port),
{reply, ok, State#server_state{serv_sock=ServSock, state=connecting}};
handle_call(irc_accept_clients, _From,
#server_state{serv_sock=ServSock, app_handler=AppHandler } = State) ->

io:format("trace: lib:handle_call accept_clients. [~p]~n", [AppHandler]),
ClientSock = server_accept(ServSock),
%***************
% Start the handler process
%***************
io:format("trace: [!!] lib:handle_call client-socket: [~p]~n", [ClientSock]),
% Pass the main app handler, serv lib handler, client sock
% And launch the handler process.
ClientInfo = #client_info{app_handler=AppHandler,serv_lib=self(),
client_sock=ClientSock},
{ ok, ClientServ } = client_handler:start_link(ClientInfo),
% Assign a new controlling process.
gen_tcp:controlling_process(ClientSock, ClientServ),
% Active the socket so that the client handler can handle the
% tcp data.
inet:setopts(ClientSock, [{packet, 0}, binary,
{nodelay, true},{active, true}]),
{reply, ok, State};
handle_call(get_cur_state, _From, #server_state{} = State) ->
% Generic method to get the current state.
io:format("trace: lib:handle_call:get_cur_state~n"),
{reply, {ok, State}, State}.

The Client Handler



handle_info({tcp, Sock, Data}, State) ->
inet:setopts(Sock, [{active, once}]),
io:format("trace: lib:info.tcp data [~p]~n", [Data]),
{Prefix, Command, Args} =
try data_lib:scan_string(Data)
catch
_:X ->
io:format("ERROR: error attempting to parse input command error:[~p]~n",[X]),
{"", (Data), ""}
end,
% Invoke the client data handler to process incoming messages.
HandleState=client_handle_data(State, {Prefix, Command, Args}),
{noreply, State};
handle_info({tcp_closed, Sock}, State) ->
%*************************
% Client has closed the connection.
%*************************
io:format("trace: lib:info.tcp_closed state:[~p]~n", [State]),
AppHandler = State#client_state.app_handler,
inet:setopts(Sock, [{active, once}]),
gen_tcp:close(Sock),
% Send a request to the handler; we lost a connection.
AppHandler ! {connection_closed},
{noreply, State#client_state{state=disconn, client_sock=nil}};
handle_info({tcp_error, Sock, Reason}, State) ->
io:format("trace: lib:info.tcp_error~n"),
inet:setopts(Sock, [{active, once}]),
{noreply, State#client_state{state=disconn}};
handle_info(Msg, State) ->
% Generic handle info handler
io:format("trace: lib:info.<generic> [~p] [~p]~n", [Msg,State]),
{noreply, State}.

Running the Application



Full Source (through subversion)

http://openbotlist.googlecode.com/svn/trunk/botlistprojects/laughingman/test/ircserver

Sunday, March 2, 2008

Laughing man project; first version of IRC library in erlang

No bot/agent system would be complete without an IRC bot agent. This is the skeleton version of the botlist-laughingman IRC bot. It is a basic Erlang IRC bot right now. It could work as a good skeleton.

Current features.
* Works with current releases of erlang (as of 3/1/2008)
* Skeleton library based on the orbitz bot
* Simple functions include sending messages to the channel, printing the messages, etc.

To compile use the makefile 'make tests' and make sure you have erlang installed. Possible eunit for the unit tests.

Based on:
http://orbitz-erlang.blogspot.com/2005/08/irc-bot.html

http://openbotlist.googlecode.com/svn/trunk/botlistprojects/laughingman/