Angel \”Java\” Lopez on Blog

June 30, 2016

Clojure: Links, News And Resources (32)

Filed under: ClojSharp, Functional Programming, Links, Lisp, Programming Languages — ajlopez @ 10:53 am

Previous Post
Next Post

More historic links about Clojure

ptaoussanis/sente
https://github.com/ptaoussanis/sente
Web Sockets

TheClimateCorporation/claypoole
https://github.com/TheClimateCorporation/claypoole/
Thread Pool

Timothy Baldridge on Clojure’s Core.Async
http://www.infoq.com/interviews/baldridge-core-async

Martin’s Programming Blog: Distributed Actors in Clojure
http://martinsprogrammingblog.blogspot.com.ar/2012/05/distributed-actors-in-clojure.html

Why Clojure Rocks | kreuzwerker Blog
http://www.kreuzwerker.de/en/blog/posts/why-clojure-rocks-2/

oakes/lein-fruit
https://github.com/oakes/lein-fruit
iOS plugin

Reagent 0.4.0: All arguments allowed
http://holmsand.github.io/reagent/news/any-arguments.html

holmsand/reagent
https://github.com/holmsand/reagent

weejulius/raiseup
https://github.com/weejulius/raiseup
CQRS sample

Lucuma – A Web Components library for ClojureScript
http://jeluard.github.io/lucuma/

JonyEpsilon/gorilla-repl
https://github.com/JonyEpsilon/gorilla-repl

There’s More to Life than Just Functions
http://bodil.org/more-than-functions/#/

webnf/webnf
https://github.com/webnf/webnf
Web Development

rkn.io – Datomic Antipatterns: Conn as a Value
http://www.rkn.io/2014/02/10/datomic-antipatterns-connnnn/

gf3/secretary
https://github.com/gf3/secretary
ClojureScript routing

RockPaperScissorsMultimethodsClojure/rockpaperscissors/src/rockpaperscissors/core.clj at master · trikitrok/RockPaperScissorsMultimethodsClojure
https://github.com/trikitrok/RockPaperScissorsMultimethodsClojure/blob/master/rockpaperscissors/src/rockpaperscissors/core.clj

Clojure Cheat Sheet (Clojure 1.3 – 1.5, sheet v12)
http://jafingerhut.github.io/cheatsheet-clj-1.3/cheatsheet-tiptip-cdocs-summary.html

damballa/parkour
https://github.com/damballa/parkour
MapReduce Hadoop

Parallel Universe
http://blog.paralleluniverse.co/2014/02/06/fibers-threads-strands/

Factual/durable-queue
https://github.com/Factual/durable-queue
Queue

Live coding with Clojure and Emacs ?
http://danielsz.github.io/2014/01/20/Live-coding-with-Clojure-and-Emacs/

Jay Fields’ Thoughts: REPL Driven Development
http://blog.jayfields.com/2014/01/repl-driven-development.html

My Links
http://delicious.com/ajlopez/clojure

Stay tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

January 2, 2015

New Month’s Resolutions: January 2015

A new year begins. Time to review past month’s resolutions:

– Add distributed features to AjErl, Erlang-like interpreter in C# [partial] see repo
– Improve ClojSharp [complete] see repo
– Improve SimpleLisp [complete] see repo
– Code generation with AjGenesis for Node [pending]
– Start Basic Script Language for C# [complete] see repo

Additionally, I was working on:

– Improve ScalaSharp [complete] see repo
– First operations in Chip8 emulator [complete] see repo
– Write Clojure samples (Ring, Compojure) [complete] see repo
– Work on Liqueed project [complete] see repo
– Improve AjScript [complete] see repo

This new month’s resolutions:

– Continue add distributed features to AjErl, Erlang-like interpreter in C#
– Improve ClojSharp
– Improve ScalaSharp
– Improve Chip8 emulator
– Code generation with AjGenesis for Node
– Improve Basic Script Language for C#
– Write JavaScript and Artificial Intelligence posts

Stay tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

December 4, 2014

New Month’s Resolutions: December 2014

It’s time to review past month’s resolutions:

– Give a talk about JavaScript and Artificial Intelligence [complete] see repo see talk read Spanish post
– Neural network in JavaScript example [complete] see repo
– Genetic Algorithms in JavaScript example [complete] see repo
– More Code Generation using AjGenesis for NodeJs [pending]
– Basic Script Language for C# [pending]
– Improve SimpleScript for JavaScript [complete] see repo

Also, I was working on:

– Improve SimpleLisp, Lisp to JavaScript compiler [complete] see repo
– Improve RuScript, Ruby interpreter in JavaScript [complete] see repo
– Improve RustScript, Rust-like interpreter in JavaScript [complete] see repo
– Create SimpleDT, simple decision tree in JavaScript [complete] see repo
– Improve ClojSharp, Clojure-like interpreter in C# [complete] see repo
– Backgammon evaluation page [complete] see repo

This new month’s resolutions:

– Add distributed features to AjElr, Erlang-like interpreter in C#
– Improve ClojSharp
– Improve SimpleLisp
– Code generation with AjGenesis for Node
– Start Basic Script Language for C#

Stay tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

July 22, 2014

ClojSharp Implementing Clojure In C# (1) The Project

Since the past decade I’m interested on Clojure. It’s a return to Lisp, but in modern times.. Clojure is implemented on the Java virtual machine, but is also implemented on. NET (AFAIK, using Dynamic Language Runtime). The version of Java compiles to Java bytecodes. There is also a version of JavaScript, called ClojureScript. The community is very active, and has brought an air of renewal within Java. It has features like immutability of his work-oriented structures in multithreading, avoiding concurrency problems. It supports Software Transactional Memory, but has been less used by what I see. Web frameworks have emerged, and has a project and dependencies manager called Leiningen. Some links in my Clojure posts.

To deliberate practice TDD (Test-Driven Development) and C#, I was building an interpreter (not a compiler to bytecodes, yet). The project:

https://github.com/ajlopez/ClojSharp

Current status:

It has a class library project, and a test project. There is also a REPL (Read Eval Print Loop) simple console application.

In Lisp, an expressions is composed by a verb and arguments, written in a list enclosed by parenthesis. For example, a list that at evaluation returns the sum of 1, 2 and 3:

(+ 1 2 3)

Here, the plus + sign is a symbol that in Lisp/Clojure refers to a form. A form receives arguments, operates on them, and returns a result. A typical form receives its arguments as evaluated expressions: the expressions are evaluated BEFORE the evaluation of the form:

(+ 1 (- 3 4) 3)

In the above example, the first argument to plus is a constant 1, and the second argument is an expression that is evaluated to –1 before the evaluation of the outer list.

But there are forms that not need evaluated arguments. They receive the arguments without evaluation. They are called special forms. I have implemented:

And I have implemented some (non special) forms as primitives in C#. Most of them could be implemented in Lisp itself, but being so basic that I preferred to implement them directly in C#, using TDD as usual:

Next topics: the Machine implementation, Context, how to use Parser and Lexer, more about expression evaluation, macros, tail recursion, etc.

Stay tuned!

Angel “Java” Lopez

http://www.ajlopez.com

http://twitter.com/ajlopez

May 21, 2014

End Of Iteration 2014w20

Filed under: C Sharp, ClojSharp, Iteration, JavaScript, NodeJs, Open Source Projects, SharpGo — ajlopez @ 10:58 am

Previous Post
Next Post

SharpGo

Go programming language interpreter in C#:

https://github.com/ajlopez/SharpGo

I added comparison operators in lexer, parse binary expression using arithmetic and comparison operators, add statements separated by semicolons, parse blocks, parse assignment. Go is a type language, so I’m building the Abstract Syntax Tree of to-be-typed nodes, before evaluating the expressions as in an untyped interpreter.

SimpleScraper

Simple HTML scraper, implemented in plain JavaScript, without dependencies:

https://github.com/ajlopez/SimpleScraper

It runs on Node.js, but it could run from browser. I improved the sample use cases, scraping two popular Argentinean news sites. The samples get an article or a frontpage, and produce JSON output.

ClojSharp

Clojure interpreter in C#:

https://github.com/ajlopez/ClojSharp

This week I added multi-functions: functions defined with different bodies according to arity (no argument, one argument, two arguments and rest, etc..) I started to add support for anonymous function macro reader

Others

A minor refactor in https://github.com/ajlopez/AcquarellaJS my syntax highlighter in JavaScript, work in progress. I added some simple samples to https://github.com/ajlopez/ScalaSamples. I started to support the add of named nodes to compiler context in https://github.com/ajlopez/ScalaSharp. I also worked on three non-public projects. More fun is coming.

Keep tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

May 9, 2014

New Month’s Resolutions: May 2014

Time to review my April 2014 resolutions:

– Continue AjLispScala [pending]
– Continue AjGenesisNode-Express [partial] see repo
– Continue AjGenesisNode-PHP [pending]
– Continue RuScript [pending]
– Continue RustScript [complete] see repo
– Distributed Messages in AjErl [partial] see repo
– Give a talk Intro to Node.js [complete] see repo see online talk
– Publish a new Node.js video tutorial [complete] see post

Additionally, I worked on:

– Start SharpGo interpreter [complete] see repo
– Start SimpleNeuron in JavaScript [complete] see repo
– Refactor, extend and publish new version of SimpleFlow [complete] see repo
– Improve SimpleScraper [complete] see repo
– Improve ClojSharp [complete] see repo
– Improve Aktores [complete] see repo

The resolutions for the new month, May 2014:

– Work on SimpleScraper, first use cases
– Continue RuScript
– Continue RustScript
– Continue SharpGo
– Continue Distributed Messages in AjErl
– Improve Mass Language
– Continue Aktores (first distributed features)

More fun is coming!

Keep tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

May 7, 2014

End Of Iteration 2014w18

Filed under: C Sharp, ClojSharp, Google, Iteration, JavaScript, NodeJs, Programming — ajlopez @ 5:07 pm

Previous Post
Next Post

Node Samples

I added a Picasa API search demo application

https://github.com/ajlopez/ExpressSamples/tree/master/MyPicasa

https://twitter.com/ajlopez/status/462919814701281281/photo/1

SimpleScraper

I added more basic functionality to my JavaScript scraper:

https://github.com/ajlopez/SimpleScraper

Now, each document element has a list of attributes. As a concrete use case, there are two console samples that generate structured JSON data from two  popular Argentinean news sites:

https://github.com/ajlopez/SimpleScraper/tree/master/samples/clarin
https://github.com/ajlopez/SimpleScraper/tree/master/samples/lanacion

https://twitter.com/ajlopez/status/463006440660017153/photo/1

SharpGo

An interpreter of Go programming language written in C#, work in progress

https://github.com/ajlopez/SharpGo

Some lexer pieces in place, and the first parse expression method.

SimpleNeuron

Artificial Neurons in JavaScript:

https://github.com/ajlopez/SimpleNeuron

I removed events: no use case for them, yet. I added the construction of a multilayer network. Next step: automatic learning using back-propagation.

ClojSharp

Clojure interpreter in C#:

https://github.com/ajlopez/ClojSharp

I implemented metadata reader. Big surgical refactor: now adding metadata produces a new object (in previous naive implementation, the metadata was attached to the original object). Now, it follows Clojure expected semantics. But TDD saved my day!

Google Code Jam

I participated in Round 1B:

https://code.google.com/codejam/contest/2994486/dashboard

I solved only one problem, check

https://github.com/ajlopez/TddRocks/tree/master/Gcj2014/Repeater

For another problem, Lottery, I had a not written solution with O(n,m). I thought that it was not good enough for processing large dataset. But, apparently, the large dataset had no hard problem. Some contestants solved the problem using O(n,m) solutions. It was an interesting problem, that deserve more thought. I didn’t understand the third problem (I confused tickets with flights)

Others

There is a new empty Laravel PHP sample at https://github.com/ajlopez/PhpSamples/tree/master/Laravel/MyLaravel. Some new node parse methods in ScalaSharp https://github.com/ajlopez/ScalaSharp. I added first map, reduce implementations to https://github.com/ajlopez/SimpleFlow. I added more features to serialization in https://github.com/ajlopez/AjErl.

I worked on three non-public projects, too.

More fun is coming.

Keep tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

April 1, 2014

End Of Iteration 2014w13

Previous Post
Next Post

AjGenesis Agents

I started to add agents support to AjGenesis for Node, Express tasks:

https://github.com/ajlopez/AjGenesisNode-Express

The idea of agents is: instead of having code to render or produce page, code, classes, the agents are queried to solve problems: render this field, render this input, create the validation code, etc. Each agent could accept or not the problem: if an agent specialized in Angular detects that Angular is not being used in the application, then it is not loaded. Work in progress.

Ruby in C#

I updated:

https://github.com/ajlopez/RubySharp

My Ruby interpreter in C#. I added local variables detection. Ruby is a language where the local variables used in an scope can be listed. I wrote code to retrieve the name of local variables from expressions.

Clojure in C#

I worked on:

https://github.com/ajlopez/ClojSharp

There are a few new primitived forms and special form, and more parser/lexer support.

Scala in C#

I started to add dynamic object support to

https://github.com/ajlopez/ScalaSharp

The idea is to have objects with defined methods. Maybe, I will re-implement the object without dynamic methods: these should be defined at compile time, instead of runtime. I’m thinking about the definition of classes for many objects, and singleton classes for only one object.

Rust in JavaScript

I updated my Rust interpreter in JavaScript:

https://github.com/ajlopez/RustScript

with the support of modules, and public functions exposed in modules. I should add the references to them, using double colon operator.

AjLisp in Scala

To practice TDD and the use of SBT (Simple Build Tool), I started:

https://github.com/ajlopez/AjLispScala

Where I’m reimplemented AjLisp ideas in Scala, using scalatest library for TDD

JavaScript Samples

To explore WebGL, canvas, and implement some code katas, I created:

https://github.com/ajlopez/JavaScriptSamples

WebGL is not easy: lot of details to setup an scene. Canvas examples were borrowed from other of my projects. To practice TDD, I started to wrote simple code katas, using SimpleUnit and Node.js

I was working on two non-public projects, too. More fun is coming.

Keep tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

March 8, 2014

New Month’s Resolutions: March 2014

Filed under: AjErl, C Sharp, ClojSharp, Clojure, Erlang, Open Source Projects, Scala, ScalaSharp — ajlopez @ 7:27 pm

Review of my February’s Resolutions:

– Complete distributed messaging in AjErl [partial] see repo
– Complete dot notation in AjLisp [pending]
– Improve ClojSharp [complete] see repo
– Work on ScaScript [partial] see repo
– Work on ScalaSharp [complete] see repo
– Add variable scope to Mass [pending]
– Complete first version Aktores actor model in C# [pending]
– More code generation tasks, templates, models in AjGenesis for Node, generating Express, Meteor, Sinatra applications [partial] see repo

To compensate missing coding, I worked on:

– Create Annalisa [complete] see repo with online web services and demo
– Start SimpleAsync [complete] see repo
– Create my first Meteor samples [complete] see repo
– Start Templie, a simple template engine in Java [complete] see repo
– Start SimpleScraper, a simple scraper in JavaScript/Node.js [complete] see repo

And I made minor improvements on DylanSharp

New month’s resolution:

– Work on DictSharp
– Give talk about Node.js Distributed Applications
– Improve SimpleGammon
– Improve Annalisa
– Add @for to Templie
– Work on PreciosaAnnalisa online web services
– Improve my Node.js Distributes Applications samples
– Work on ScalaSharp
– Improve ClojSharp
– Improve SimpleAsync, do operation (functions in parallel)
– Improve Aktores
– Distributed messages in AjErl
– Add variable scope to Mass language
– Start code generation as a service

More fun is coming.

Keep tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

February 7, 2014

New Month’s Resolutions: February 2014

Review of my January’s Resolutions:

– Start to implement Akka-like actor model in C# [complete] see repo
– Start to implement Scala interpreter in JavaScript [complete] see repo
– Work on AjErl [complete] see repo
– Work on Mass (I have many ideas to implement as module pattern and variable scope access) [pending]
– Work on DylanSharp [complete] see repo
– Start an implementation of ML (JavaScript? C#?) [pending]

I also worked on:

– Improving Scala interpreter in C# [complete] see repo
– Adding dot notation to Lisp interpreter in C# [complete] see repo
– Improving Ruby interpreter in JavaScript [complete] see repo
– Improving Clojure-like interpreter in C# [complete] see repo
– First templates, tasks generating Sinatra application in AjGenesis for Node [complete] see repo

My new month’s resolutions:

– Complete distributed messaging in AjErl
– Complete dot notation in AjLisp
– Improve ClojSharp
– Work on ScaScript
– Work on ScalaSharp
– Add variable scope to Mass
– Complete first version Aktores actor model in C#
– More code generation tasks, templates, models in AjGenesis for Node, generating Express, Meteor, Sinatra applications

More fun is coming

Keep tuned!

Angel “Java” Lopez
http://www.ajlopez.com
http://twitter.com/ajlopez

Blog at WordPress.com.