jeffshrager / elizagen.org

Genealogy of Elizas
247 stars 34 forks source link

Emulate (CONTROL T) #9

Open pdewacht opened 10 years ago

pdewacht commented 10 years ago

This depends on how much historical accuracy we really want... The original code uses (CONTROL T), which turns off line buffering. (See BBN Lisp documentation at: http://bitsavers.trailing-edge.com/pdf/bbn/The_BBN-LISP_System_Apr69.pdf)

This probably means that the doctor is intended to answer the patient immediately when they finish a sentence, without them needing to press the Return key. The start-up instructions also hint at this:

PLEASE TERMINATE INPUT WITH A PERIOD OR A QUESTION MARK.

Not implementing this behavior means that patients get confusing output when they type two sentences on a single line. And we probably also print a spurious empty line before the doctor's responses.

There seems no portable way to implement this. On Unix you'd need to fiddle with termios, and on Windows there's the Console API. There doesn't seem to be any Lisp library that provides a portable interface to this functionality.

jeffshrager commented 10 years ago

Yeah, down at the char-by-char reading level we'd have to monkey with god knows what. I think it's so close to perfect as is, that our job is done here! :-)

----- Original Message -----

This depends on how much historical accuracy we really want... The original code uses (CONTROL T), which turns off line buffering. (See BBN Lisp documentation at: http://bitsavers.trailing-edge.com/pdf/bbn/The_BBN-LISP_System_Apr69.pdf)

This probably means that the doctor is intended to answer the patient immediately when they finish a sentence, without them needing to press the Return key. The start-up instructions also hint at this:

PLEASE TERMINATE INPUT WITH A PERIOD OR A QUESTION MARK.

Not implementing this behavior means that patients get confusing output when they type two sentences on a single line. And we probably also print a spurious empty line before the doctor's responses.

There seems no portable way to implement this. On Unix you'd need to fiddle with termios, and on Windows there's the Console API. There doesn't seem to be any Lisp library that provides a portable interface to this functionality.


Reply to this email directly or view it on GitHub: https://github.com/jeffshrager/elizagen/issues/9

ambiamber commented 1 year ago

@pdewacht

Thanks for pointing out that an SDS 940 has a status key! I've been collecting status keys for quite a while and I've never seen any old big iron other than from DEC with a status key. https://en.wikipedia.org/wiki/Status_key

I added the SDS 940 to the Talk page of the Status Key article for now. Once I understand it enough I will add it to the article. I hope you actually read the Status Key page because you have misconceptions about CONTROL-T and its long history. You wrote:

turns off line buffering

That is entirely incorrect. The output comes directly out of the system's monitor (kernel, etc.) and bypasses all buffers.

larsbrinkhoff commented 1 year ago

@ambiamber, agreed, very interesting! TENEX was influenced by the Berkeley system, so TOPS-20 must have got it from there.

I didn't see the information in this issue, but I found it on page 23.10 in the linked pdf. Added here for completeness: control-t

pdewacht commented 1 year ago

@ambiamber You misunderstood me, I wasn't talking about a Ctrl-T keystroke.

The Eliza code has the function call (control t) near the top: https://github.com/jeffshrager/elizagen.org/blob/5671ce249fae09c34eef412169c8383662948a0b/1966_Cosell_BBNLISP/coselleliza1969and1972.transcript#L61

The control function is documented on page 14.10 of the BBN Lisp manual: afbeelding

So the effect of the (control t) call is to turn off line buffering.

ambiamber commented 1 year ago

@pdewacht never mind.

ambiamber commented 1 year ago

@larsbrinkhoff

TOPS-20 must have got it from there

DEC RSTS/E has a status key and it came before TOPS-20 too. (post hoc ergo propter hoc).

larsbrinkhoff commented 1 year ago

It's not a question about which came before the other.

ambiamber commented 1 year ago

Intent is the most difficult thing to prove.