Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Self-modifying Common Lisp
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Austin Ting @ Libgirl Co.,Ltd.
July 09, 2017
Programming
0
230
Self-modifying Common Lisp
Author: Shih-Chia Chen (Shaka)
Email:
[email protected]
Austin Ting @ Libgirl Co.,Ltd.
July 09, 2017
Tweet
Share
Other Decks in Programming
See All in Programming
AIフル活用時代だからこそ学んでおきたい働き方の心得
shinoyu
0
130
OSSとなったswift-buildで Xcodeのビルドを差し替えられるため 自分でXcodeを直せる時代になっている ダイアモンド問題編
yimajo
3
620
AI時代のキャリアプラン「技術の引力」からの脱出と「問い」へのいざない / tech-gravity
minodriven
21
7.2k
2026年 エンジニアリング自己学習法
yumechi
0
130
React 19でつくる「気持ちいいUI」- 楽観的UIのすすめ
himorishige
11
7.4k
Data-Centric Kaggle
isax1015
2
770
CSC307 Lecture 01
javiergs
PRO
0
690
CSC307 Lecture 04
javiergs
PRO
0
660
Oxlintはいいぞ
yug1224
5
1.3k
AI巻き込み型コードレビューのススメ
nealle
1
220
責任感のあるCloudWatchアラームを設計しよう
akihisaikeda
3
170
Best-Practices-for-Cortex-Analyst-and-AI-Agent
ryotaroikeda
1
100
Featured
See All Featured
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
0
350
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
4.2k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
77
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
710
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
430
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
320
Beyond borders and beyond the search box: How to win the global "messy middle" with AI-driven SEO
davidcarrasco
1
51
SEOcharity - Dark patterns in SEO and UX: How to avoid them and build a more ethical web
sarafernandez
0
120
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.4k
Why Our Code Smells
bkeepers
PRO
340
58k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3k
Agile Actions for Facilitating Distributed Teams - ADO2019
mkilby
0
110
Transcript
SELF-MODIFYING LISP Dialect Design & Implementation Shih-Chia Chen (Shaka) @danielviolin
Libgirl Co., Ltd. 2017/July/8th
PURPOSE IS AI Real Artificial Intelligence(AI) requires critical thinking ability.
step-by-step follower is not pre-programmed program = step-by-step follower.
PURPOSE IS AI Static programs not intelligent mainstream machine learning
programs learn by static algorithm.
PURPOSE IS AI We need a program that “criticize” itself.
So we built self-modifying lisp program.
DIALECT FEATURES FOR SELF MODIFICATION Closure Property Every Symbol is
a Function Code = Data sharing process segment (modern OS process management. Code segment and data segment is separate.)
PROGRAM STRUCTURE Function Name Parameters Function Body x y f
(p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL = APPLY To eval a symbol x = (x)
= (x default-arg-0 default-arg1 …) default value of a symbol is itself
EVAL A FORM (1 (f (cons 1 x) 3)) Function
Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons 1 x) 3)) Function
Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons (1 0) x) 3))
Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons (quote 0 0) x)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons (quote 0 0) x)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons (quote 0 0) (x))
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons (quote 0 0) y)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (cons (quote 0 0) y)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (quote (quote 0 0) y)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (quote (quote 0 0) y)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (quote (quote 0 0) y)
(3))) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (quote (quote 0 0) y)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (f (quote (quote 0 0) y)
3)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (x (quote (quote 0 0) y)
1)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (x (quote (quote 0 0) y)
1)) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (x (quote (quote 0 0) y)
(1 0))) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (x (quote (quote 0 0) y)
(quote 0 0))) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 (x (quote (quote 0 0) y)
(quote 0 0))) Function Name Parameters Function Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 y) Function Name Parameters Function Body
x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (1 y) Function Name Parameters Function Body
x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
EVAL A FORM (quote y 0) Function Name Parameters Function
Body x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
ALL THE CODE IS ON THE TABLE Function Name
Parameters Function Body a (1 (f (cons 1 x) 3)) x y f (p0) (x p0 1) 1 (p2) (quote p2 0) f2 (defun (f3 f f2) (quote cons (quote pf0 pf1)))
WHEN THE CODE CHANGES ITSELF Function Name Parameters Function Body
f2 (defun (f3 2) (quote cons (quote pf0 pf1)))
WHEN THE CODE CHANGES ITSELF Function Name Parameters Function Body
f2 (defun f2 (quote cons (quote pf0 pf1)))
OR MORE COMPLICATED Function Name Parameters Function Body x y
f (p0) (p0 x (defun x 1)) 1 (p2) (f2 (defun f (quote p2 0)) f2 (defun (f3 2) (quote cons (quote pf0 pf1)))
BEING A LISP ENSURES TURING-COMPLETE Primitives cons car cdr eq
when atom quote t nil defun
LITTLE DEMO
FUTURE WORKS Building a pool of self modifying programs with
management tools. Make the dialect more like Common Lisp
THANK YOU