14836
Progress Journals & Experimental Routines / Re: ADARQ's journal
« on: April 16, 2012, 06:59:10 am »oh one more thing, this is pretty cool.. using the "nop input module", I can turn an irc/live chat session into a guile session.
. ^nop causes the bot to "add stuff" to each line it receives, so normal chat text, can become processed using my triggers..
for example
^nop(ina) \|^e\|^guile <-- this causes guile to append \|^e\|^guile to each line received, then processes it.. so..
typing:
(display 1) turns into (display 1) |^e |^guile, which causes guile to parse (display 1) resulting in 1 being outputted..
here's an example:
04:40 <@z> (display (list "hey"))
04:40 < xdd> (hey)
04:41 <@z> (display (length (list "hey")))
04:41 < xdd> 1
04:41 <@z> (display (%global-site-dir))
04:41 < xdd> /usr/local/share/guile/site
04:43 <@z> (display (remainder 10 4))
04:43 < xdd> 2
04:47 <@z> (number->string (+ 1 2))
04:47 <@z> (display (number->string (+ 1 2)))
04:47 < xdd> 3
05:01 <@z> (procedure-documentation display)
05:01 <@z> (display (procedure-documentation display))
05:01 < xdd> #f
05:01 <@z> (display (procedure-documentation 'display))
05:01 <@z> (display (procedure-documentation sort))
05:01 < xdd> #f
05:02 <@z> (display (random))
05:02 <@z> (display (random 4))
05:02 < xdd> 3
05:02 <@z> (display (random 100000))
05:02 < xdd> 50621
05:02 <@z> (display (random 10000000000000))
05:02 < xdd> 6312491691827
05:02 <@z> (display (random 100000000000000000000000000000000000000000000))
05:02 < xdd> 78306622436512418053130718978773471728041129
pretty cool.. ^nop is real powerful.. ^modfiy will be insanely powerful once i code it.
~
