- 14
- 30
Livestream of @Neuralink demonstrating “Telepathy” – controlling a computer and playing video games just by thinking https://t.co/0kHJdayfYy
— Elon Musk (@elonmusk) March 20, 2024
- 23
- 35
The Official RDrama Computer Science Reading Group
My dear !codecels, hello and welcome to the first meeting of RDrama's Computer Science Reading Group! Here's the idea - we (read: I) pick a computer science textbook, then post a list of sections and exercises from that textbook each week. In the thread, feel free ask questions, post solutions, and bully people for asking stupid questions or posting stupid solutions. If you don't want to read along, I'll post the complete exercises in the OP, so you can solve them without needing to read the book.
SICP
The book I'm starting with is 'the Structure and Interpretation of Computer Programs' (abbreviated SICP). It's a software engineering textbook written by Gerald Jay Sussman and Hal Abelson from MIT. The book builds programming from the ground up: starting with a very simple dialect of Scheme and growing it into a language with lazy evaluation, object-orientation and a self-hosting compiler. It's a fun book: the exercises are hands-on and interesting, the writing is informative without being droll, and both the book itself and a corresponding lecture series (complete with a 80s synth rendition of 'Also Sprach Zarathustra') are available for free online.
Languages
The book uses (a small subset of) Scheme as its primary language, but feel free to try using a different language. The book's dialect of scheme is available through Racket, but most lisps will work with only minor changes. Other dynamically-typed, garbage-collected languages with higher-order functions will also not require much hacking: there is an edition written in JavaScript , as well as a partial adaptation to python . High-level, statically typed languages might also work: Java/Kotlin/C# seem doable, but I don't know those languages well. Strongly typed languages like Haskell will require some real hacks, and I'd avoid doing it in C, C++ or Rust.
Exercises
The book is split into five chapters:
- Building Abstractions with Procedures
- Building Abstractions with Data
- Modularity, Objects and State
- Metalinguistic Abstraction
- Computing with Register Machines
This week, I'll be posting exercises from the first chapter. The chapter is pretty easy for those familiar with programming already, so I just want to get it out of the way. Here are the selected exercises:
Exercise 1.8
Newton's method for cube roots is based on the fact that if
y
is an approximation to the cube root ofx
, then a better approximation is given by the value(x/y² + 2y) / 3
. Use this formula to implement a cube-root procedure which is wrong by at most0.01
.
Exercise 1.12
The following pattern of numbers is called Pascal's Triangle.
1
1 1
1 2 1
1 3 3 1
1 4 6 4 1
...
The numbers at the edge of the triangle are all 1, and each number inside the triangle is the sum of the two numbers above it. Write a procedure that computes elements of Pascal's triangle.
Exercise 1.18
Devise a procedure generates an iterative process for multiplying two integers in terms of adding, doubling, and halving and uses a logarithmic number of steps.
Exercise 1.31
Write a procedure called
product
that returns the product of the values of a function at points over a given range (product(l, r,step,f) = f(l) * f(l+step) * f(l + 2 * step) * ... * f(r)
). Show how to definefactorial
in terms ofproduct
. Also use product to compute approximations to using the formulaπ/4 = (2 * 4 * 4 * 6 * 6 * 8 ...) / (3 * 3 * 5 * 5 * 7 * 7 ...)
Exercise 1.43
If
f
is a numerical function andn
is a positive integer, then we can form then
th repeated application off
, which is defined to be the function whose value atx
isf(f(...(f(x))...))
. For example, iff
is the functionx → x + 1
, then then
th repeated application off
is the functionx → x + n
. Iff
is the operation of squaring a number, then then
th repeated application off
is the function that raises its argument to the2 * n
th power. Write a procedure that takes as inputs a procedure that computesf
and a positive integern
and returns the procedure that computes then
th repeated application of f. Your procedure should be able to be used as follows:repeated(square,2)(5) = 625
Have fun!
- 58
- 83
Rafael putting his @cybertruck to work on Kane Creek Road. pic.twitter.com/BCLaLg4rS1
— Kyle Field (@mrkylefield) March 14, 2024
https://twitter.com/mrkylefield/status/1769549346100629720
Some of the other hardcore offroading the Cybertruck os capable of
https://twitter.com/mrkylefield/status/1769416291650343372
- Sphereserf3232 : Wait apex is a source game?
- BWC : Yes, but it runs on a very modified version of the Source Engine iirc
- 20
- 102
Respawn and EA have postponed the North American Finals in the wake of the “competitive integrity” of the game being compromised. This involved a wild situation where someone was giving the pros hacks like aimbots and wallhacks as they were playing in the Finals event, effectively ruining the entire thing without anyone actually attempting to cheat. Here's what that looked like (warning: language):
This has led to a mass of complaints about Apex's anti-cheat systems, which clearly failed in a massive way for this situation. But it also speaks to just how advanced cheats have become as this is a private lobby for pros playing in an esports final.
Not that this is necessarily related, but Respawn was just hit days ago with 23 layoffs including Apex Legends developers, some of whom were longtime veterans. Though if anything, this shows that EA needs to beef up Apex's security team to some extent as something like this requires all hands, or more hands, on deck than they currently have now, it seems.
Should have learned to code better
Easy Anti-Cheat's response- It wasn't me
- 12
- 15
- 3
- 30
Hacker News discussion: https://news.ycombinator.com/item?id=39709089
- 9
- 16
If you see this post, I was able to make this post on Ladybird Web Browser lol
- 84
- 108
Love you !codecels, so I'm gonna show you how to get GPT-4 access for free. A few major caveats:
Scale will definitely shut this down at some point, so use it while it's available.
This might not actually be GPT-4. There's not really a way of knowing. I'm about 98% sure it is, but they may swap it out for 3.5 Turbo during outages (?)
You need some form of API interpreter for the JSON it spits out. Here, I'm using TavernAI, which is designed to be a Character.AI-like "chat" interface, with the ability to import and design "personalities" of characters. Great for coomers. Here's some pre-made characters, if you're interested (Some NSFW). Just download the image and import it.
Every message you send will pass through OpenAI's API, Scale, and If you don't change the API key, it will also pass through the 4chan guy who hosts the github's Spellbook deployment. There is exactly ZERO expectation of privacy. Don't be retarded and type illegal shit or personal info.
As of right now, the OpenAI API is having an outage. These are pretty frequent. (This is why I'm writing this thread rn instead of fucking around with GPT-4)
Now, how to actually set this up, using TavernAI, for lazy retards:
Have Node.js and git installed and know how to use them. This is /h/slackernews, I won't explain this part.
Make a temporary email. Just google 'temp email'. Turn on a VPN for the entire session as well, if you're really paranoid.
Head over to https://spellbook.scale.com/ and make an account with the temp email.
Create an "App", name and desc. don't matter.
Make a variant, and select GPT-4 in the dropdown.
- If you're wanting to use the API with Tavern to emulate a chatbot, you should add the following to the 'User' section:
Complete the next response in this fictional roleplay chat.
{{ input }}
Set the 'Tempurature' to somewhere between 0.6 and 0.9. 0.75 works fine for me.
Set the maximum tokens to 512 for chatbot length responses. (You can increase this but it requires tweaking the TavernAI frontend.)
Save the variant. Go to the variant and hit "Deploy". You'll see a "URL" and an "API Key". Copy these down or come back here in a minute.
Open a terminal in a new folder, and run
git clone https://github.com/nai-degen/TavernAIScale
Now run
cd .\TavernAIScale\
then.\Start.bat
(or.\start.sh
for lincux)TavernAI should launch automatically, but if it doesnt, go to
http://127.0.0.1:8000/
in your browser.In Tavern, go to 'Settings' on the right. Switch API to 'Scale'. Copy the API Key from the Spellbook page that you saw earlier into the API Key field. Same thing with the URL. Press 'Connect' to verify it's working. If it fails, either the API is down or you pasted the wrong Key / URL. Make sure you're using the URL from the URL field here:
- Now, use one of the default anime characters , download a coomer character from here, or make your own.
- The API has many other uses, obviously, but the chatbot is the simplest way to get this up and running. Try fucking around with the "Main Prompt" and "NSFW Prompt" in the settings for some interesting results, or to tweak your desired output. Try pressing "advanced edit" on a character (or making your own) and messing around with personas and scenarios. It's pretty damn cool.
That's it. Have fun until this shit dies in like 3-4 days. Please try not to advertise this or make it known outside of rdrama and /g/. We don't want Scale to shut this down earlier than they already will.
- 35
- 49
- 68
- 138
- 43
- 49
To nobody's surprise, Gab's "unbiased, uncensored" chatbot is specifically instructed to take a number of right-wing stances. Here's a quick comparison across around a month of them tweaking it, both to change its behavior and to try and cover their ass wrt the prompt https://t.co/o6ITFP60bd pic.twitter.com/jKAuIIod5W
— alexa! (@frog89348645) March 4, 2024
- 12
- 44
TLDW
Hope you're having a lovely day
"Smart" shit connecting to the internet is fricking r-slurred and shady companies can and will abuse this to change Tos/features. Companies are scum
Roku's expensive butt TV literally told it's users to accept an update (no other options, you can't even change to a different input) and part of the update is accepting you can't sue them (you must accept binding arbitration)
Compares Roku to a male feminist
Makes a very oblique refrence to Gavin McGinnis not allowing his wife to own a car and how that was a form of control and part of their divorce (some pretty deep lore, idk why he knows about that unless he's a fellow MATI enjoyer)
Continues talking about how the elite (manufacturers) get the proletariat (consumers) to fight among each other (subversion of the masses)
General Opt-in vs opt-out complaints because glowie TVs are always opt-out (if that)
Call for freedom, gets close to Tedposting This will continue to happen as along as consumers don't opt-out of purchasing shit products. Collective action is necessary.
Hopes you learned something
- 3
- 14
Apparently they might make St Patrick out of an AI algorithm?
- 228
- 184
- 54
- 148
- 7
- 30
Bike chads stay winning
Discussion question for all of the carcels here: how are cars supposed to be promoting "freedom" again?