Summary

This document discusses artificial intelligence (AI) and its implications in the legal field. It covers topics including AI theory, machine learning, and practical examples of AI system applications. The document also explores the legal implications of using AI in legal processes and decision-making.

Full Transcript

SMU Classification: Restricted Emerging Technologies and Law Artificial Intelligence SMU Classification: Restricted In this Video… What is AI really? How “machine learning” works (but too briefly) How to think about AI systems in law ...

SMU Classification: Restricted Emerging Technologies and Law Artificial Intelligence SMU Classification: Restricted In this Video… What is AI really? How “machine learning” works (but too briefly) How to think about AI systems in law SMU Classification: Restricted What it sounds like… SMU Classification: Restricted What It Actually Is The Support Vector Machine (Vapnik & Chervonenkis, 1963) in Python library code. https://scikit-learn.org/stable/modules/generated/sklearn.svm.LinearSVC.html#sklearn.svm.LinearSVC A 110M network (“LEGALBERT”) trained on a 12gb corpus of legal documents by Chalkidis et al, 2019 An open-sourced adaptation of GPT2 https://huggingface.co/EleutherAI/gpt-j-6b/tree/main SMU Classification: Restricted Modern AI Theory Turing, 1950: “AI is about building machines that think” But “machine” and “think” are undefinable, not worth asking this question Instead: imitation game I know it when I (can’t) see it So what if AI passes the Turing test? SMU Classification: Restricted The Textbook Definition(s) of AI Russell and Norvig, Artificial Intelligence: A Modern Approach (2014) SMU Classification: Restricted Modern AI Systems Rules-based or Machine learning or “symbolic” AI “statistical” AI SMU Classification: Restricted Richard Susskind, Proceedings of the 1st Intl Conf AI & Law, 1987 SMU Classification: Restricted The program holds knowledge of the Divorce (Scotland) Act 1976, of relevant judicial precedents, and also contains some legal heuristics. It is designed, once the facts have been elicited from the user, to inform him whether there are grounds for divorce… The knowledge of the legal domain was, in the first instance, culled largely from primary and secondary written legal sources, that is, from legislation, case law, and standard legal textbooks. Initial tentative representations of the field of law were refined in light of consultation with experienced legal practitioners. The knowledge is represented in the knowledge base as a network of interrelated rules that can be altered with little fuss: it is a flexible, rule-based system. The corpus of knowledge can be regarded as a set of possibilities - a search space - which the system must explore with the guidance and direction of the user. At the beginning of the interaction, and periodically thereafter, the user is required to enter some basic data, such as the names of parties, relevant dates, and so forth. However, the principal ways in which the user apprises the system of the facts of a case are through "yes", "no", or "don't know" responses to questions asked of him and through selections from menus. The order in which the system explores possible solutions to problems is conditioned by the system's inference engine, which can best be described as facilitating a "user-controlled backward-chaining" reasoning mechanism. Very broadly speaking, an expert system that backward-chains starts its reasoning process at the conclusion it is trying to reach, and moves backwards through its body of rules in search of premises that will justify that conclusion. SMU Classification: Restricted motoraccidents.lawnet.sg SMU Classification: Restricted Problems with Rule-based AI Costly to specify every rule How to build AI for chess? For Go? For law? Strategy: invest resources to gather examples rather than experts; code the algorithm by example SMU Classification: Restricted I am writing bcos king in “Machine Learning” Congrats! You’ve won our recent lottery… my country died n left large inheritnce.. Branch of AI research that uses statistical methods to get computers to perform tasks without explicit instructions (Arthur Samuel) Dear Friend, it’s been a Your vaccination while. I need your help. Consider: How would you design a appointment has been Can you buy me this system that identifies email spam? successfully scheduled… Apple Pay card? “Explicit instructions”: rule-based AI system We are pleased to No explicit instructions: statistical/ML inform you that your URGENT: YOUR AI system application for… MORTGAGE IS OVERDUE SMU Classification: Restricted ML-based Systems Email Lottery Inheritance Typos Source Truth Label I am writing bcos king Congrats! You’ve won in my country died n 1 1 0 0 Unfamiliar Spam our recent lottery… left large inheritnce.. 1 2 2 0 0 2 Unfamiliar Spam Your vaccination Dear Friend, it’s been a 3 0 0 0 Familiar Not Spam appointment has been while. I need your help. successfully Can you buy me this scheduled… 3 Apple Pay card? 4 0 0 0 Familiar Spam 4 5 0 0 0 Familiar Not Spam We are pleased to URGENT: YOUR inform you that your MORTGAGE IS 6 0 0 0 Familiar Not Spam application for… OVERDUE 5 6 SMU Classification: Restricted ML-based Systems Email Lottery Inheritance Typos Source Truth 1 1 0 0 Unfamiliar Spam Regression 2 0 0 2 Unfamiliar Spam Trees 3 0 0 0 Familiar Not Spam 4 0 0 0 Familiar Spam Neural Networks 5 0 0 0 Familiar Not Spam Etc 6 0 0 0 Familiar Not Spam ‘Raw’ Data Structured Dataset Learning Algorithm / Model Can involve rule-based/statistical code here also 𝑃𝑃 𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠 = 0.2 × 𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿 + 0.00 × 𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼 + 0.05 × 𝑡𝑡𝑡𝑡𝑡𝑡𝑡𝑡𝑡𝑡 + 0.2 × 𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠 Classification Algorithm / Trained Model /“Hypothesis” SMU Classification: Restricted ML-based Systems Hi Jerrold, I need some legal help with lottery winnings that my parents left me as part of my inheritance… 𝑃𝑃 𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠 = 0.2 × 𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿 + 0 × 𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼 + 0.05 × 𝑡𝑡𝑡𝑡𝑡𝑡𝑡𝑡𝑡𝑡 + 0.2 × 𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠 Score = 0.2 Prediction: Not spam (assuming >0.5 cutoff) Notice: this simple ‘AI’ is very explainable. SMU Classification: Restricted How does the learning work? Email Lottery Inheritance Typos Source Truth 1 1 0 0 Unfamiliar Spam Regression Trees 2 0 0 2 Unfamiliar Spam 3 0 0 0 Familiar Not Spam 𝑃𝑃 𝑠𝑠𝑠𝑠𝑠𝑠𝑠𝑠 = 0.1 × 𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿 + ⋯ 4 0 0 0 Familiar Spam Neural Networks 5 0 0 0 Familiar Not Spam Etc 6 0 0 0 Familiar Not Spam Data Learning Algorithm / Model Prediction Algorithm Where the magic happens SMU Classification: Restricted “Learning” from the data On the right we have a scatterplot found in a Singapore judgment Can we use it to learn a prediction algorithm for drug trafficking sentences (Y) given quantity trafficked (X)? That means not just for a specific gram range, but for all gram ranges, even those gaps in between Supervised learning tries to find a “best fit” pattern for E[Y|X] Makes certain assumptions Vasentha d/o Joseph v Public Prosecutor Linear regression is when we assume a line can fit this SGHC 197 at SMU Classification: Restricted Machine Learning on Data While humans can easily “eyeball” the line, we can’t do it for more than 2 (3?) dimensions. But math can: Define a measure of “fit” E.g. “least squares” distance between points on the line to data points Specify line equation – determined by “coefficients” (the changing numbers >>) See how well it fits See if changing the equation improves the fit If so, move to new equation Repeat until stable https://dphi.tech/blog/tutorial-on-linear-regression-using-least-squares/ Most ML algorithms operate on the same principle 18 SMU Classification: Restricted Regression Analysis The linear regression line implied by the scatterplot data was: Sentence = 6.1597 + 0.6691 x Grams Therefore, E[Sentence|8.98 grams] = 6.1597 + 0.6691 x 8.98 = 12.168 years This is the ML prediction if we use a single variable linear regression model “77 Since the present case involves 8.98g of diamorphine, the indicative starting point would be within the range of 10−13 years’ imprisonment. As the quantity involved in this case is at the high end of the range, I take as an indicative starting point a sentence of 12 years’ and nine months’ imprisonment.” SMU Classification: Restricted Legal “Predictions” Plaintiff is a 4-year-old girl. On 27 July, 2020, she visited the defendant’s drive-thru with her mother… 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 = 0.2 × 𝑑𝑑𝑑𝑑𝑑𝑑𝑑𝑑 + 0.2 × 𝑏𝑏𝑏𝑏𝑏𝑏𝑏𝑏𝑏𝑏 + 0.05 × 𝑏𝑏𝑏𝑏𝑏𝑏𝑏𝑏𝑏𝑏 + ⋯ Score = 0.7. Prediction: Liable. SMU Classification: Restricted Neural Networks 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 = 0.20 × 𝑁𝑁𝑁𝑁 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 = 0.2 × 𝑑𝑑𝑑𝑑𝑑𝑑𝑑𝑑 + ⋯ + 0.50 × 𝑁𝑁12 Neuron 1 in Layer 1  “N11” + 0.30 × 𝑁𝑁13 N21 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 = 0.33 × 𝑁𝑁𝑁𝑁 = 0.33 × 𝑁𝑁𝑁𝑁 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 = 0.4 × 𝑑𝑑𝑑𝑑𝑑𝑑𝑑𝑑 + ⋯ + 0.33 × 𝑁𝑁12 + 0.33 × 𝑁𝑁22 N12 + 0.33 × 𝑁𝑁13 + 0.33 × 𝑁𝑁23 N22 N31 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 𝑃𝑃 𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙𝑙 = 0.3 × 𝑑𝑑𝑑𝑑𝑑𝑑𝑑𝑑 + ⋯ = 0.40 × 𝑁𝑁𝑁𝑁 + 0.40 × 𝑁𝑁12 Each number here is a coefficient or N13 + 0.20 × 𝑁𝑁13 a “parameter” N23 SMU Classification: Restricted Large Neural Networks https://tikz.net/neural_networks/ SMU Classification: Restricted Large Language Models https://heidloff.net/article/foundation-models-transformers-bert-and-gpt/ GPT3.5 has 175 billion parameters SMU Classification: Restricted Language Modelling and Generative AI Say we want to write emails, not label them A “language model” is created by taking a I am writing bcos king in Congrats! You’ve won large corpus of text, deleting words, and lottery… our recent ______… my country died n left training the model to predict missing words large inheritnce.. ______... Generative AI is really a subset of predictive AI Dear Friend, it’s been a Given word 1, predict word 2 Your vaccination ______ while. I need your help. appointment has has been been successfully This scales easily: Given sentence 1, predict successfully scheduled… Can you buy me this scheduled… sentence 2. Then now that you have predicted Pay card? Apple ______ card? sentence 2, use that and predict sentence 3… If sentence 1 is a question, then sentence 2 is We are pleased to URGENT: YOUR the predicted answer inform you that your MORTGAGE IS OVERDUE ______ application ______ for…for… Everything else we saw previously holds 24 SMU Classification: Restricted Getting to ChatGPT 1990s – “Bag-of-Words”: representing docs via simple word counts 2013 – Word Vectors: a better way to represent docs using vectors trained on actual texts 2017 – “Attention”: a new network module type that allows for variable rather than fixed parameters 2019 – Transformers: NN archetype built on attention modules that better model long texts and allow parallel computation  the first LLM “BERT” 2020 – RLHF: a way to fine-tune LLMs towards producing outputs rated highly by humans using a separate rater network 2021 – GPT3; 2022 – InstructGPT/ChatGPT; late 2022 – GPT4 Generative AI is not new https://towardsdatascience.com/all-you-need-to-know-about-attention-and-transformers-in-depth-understanding-part-1-552f0b41d021#4c16 SMU Classification: Restricted Legal Implications All machine learners/NNs/LLMs are matrix multiplications Parameters are numbers computed from data, will necessarily reflect what the data says (and does not say) “Learning” is a metaphor for updating parameters “Machine” is a metaphor for the mathematical matrices and algorithms Or, ChatGPT is an Excel table writ (very) large And by the way, LLMs are more than just ChatGPT The power behind LLMs is that next word/sentence estimation really encompasses a wide range of (legal) tasks But the fact that it is really just math does not mean it is nothing to worry about (quite the contrary) SMU Classification: Restricted https://cmp.smu.edu.sg/sites/cmp.smu.edu.sg/files/pdf/14_AMI17_GettingAIWrong.pdf SMU Classification: Restricted Why do we consistently get AI wrong? AI is by definition a human imitation game Market incentives to manipulate narratives Few have the technical training to properly; even fewer actually want to know SMU Classification: Restricted Legal Dispositionism and Artificially Intelligent Attributions (link) Dispositionism: A rational agent has internal reasons, motives, and intentions for acting (the “disposition”) So we fault them for ‘bad’ actions And hold them to informed consent (e.g. contracts, data protection laws, etc) Calls for AI personality symptomatic of bias in law towards dispositionism When AI takes over, a missing person problem We also instinctively tend to dispositionise AI by Wilson, Cast Away giving it needs, wants, morals, thoughts, and a body Example from: Hanson, 2008 SMU Classification: Restricted The Missing Person Problem The law assumes that persons {drive, contract, … , argue cases} But, now, AI does it instead. Therefore, the law {is ill-equipped for AI, will be disrupted, … , needs reform} And, in particular, we need to identify who else to hold liable/should consider AI personality. SMU Classification: Restricted The AI and the Situation BUT psychologist: actions result as much, if not more, from external circumstances (the “situation”) Yet we are systematically biased towards attributing actions to disposition while missing the situation “Fundamental Attribution Error” (Ross, 1977) Do we focus too much on ‘the AI’? AI’s “situation”: regulator, manufacturer, programmer, operator, users, etc SMU Classification: Restricted Case Study in the Article DABUS litigation filed by the “Artificial Inventor Project” Argues that DABUS (an AI system should be registered as patent inventor) More recently, trying similar arguments with copyright. See e.g. Thaler v Perlmutter (2023) DABUS “perceives like a person, thinks like a person, and subjectively feels like a person, abductively implicating it as a person” From a rather hard to get article published by Thaler in the ‘Journal of Artificial Intelligence and Consciousness’ Invention apparently “autonomously generated” by DABUS. Really? In what sense is DABUS truly ‘autonomous’? Note: not enough to show that AI could be autonomous in theory, we need to show this specific system to be autonomous in fact Interesting how far the courts entertained these arguments (often, uncontested) Some courts bought the hype and went close to suggesting DABUS could be inventor Some (mostly senior) courts (thankfully) didn’t; AIP failed in all jurisdictions so far SMU Classification: Restricted Lawyers framing AI dispositionally seldom seem to realise they may be personifying maths. Reinforced by science fiction, our dispositionist tendencies lead us to conceive of AI systems as autonomous beings, seeing disposition when we should be seeing situation. This tendency to personify AI has been identified by AI researchers as an ‘anthropomorphic bias’ and by legal scholars as an ‘android fallacy’. … Le g a l n a r r a t ive s w h ich d is p o s it io n is e AI m u s t t h e r e fo r e b e s cr u t in is e d. Notwithstanding the imagery that wishful AI mnemonics conjure, they are in e xa ct m e t a p h o r s fo r in e vit a b ly st a t ist ica l co m p u t a t io n s. To recall, ‘neurons’ are standalone statistical algorithms which compute numerical weights from data. ‘Training’ is the process of passing data through algebra to compute these weights. ‘Attention’ means increasing the numerical weights accorded to outputs from certain parts of the network. ‘Memory’ is particular type of neuron (i.e. computation) which feeds into itself such that previous computations influence subsequent ones more directly. Th e s e m e t a p h o r s m a k e t h e m a t h s a ppe a r a s if it h a s it s o w n m in d b u t n e it h e r e n t a il n o r im p ly t h a t it d o e s. As Ca r d o zo CJ fa m o u s ly h e ld , ‘[m ]e t a p h o r s in la w a r e t o b e n a r r o w ly w a t ch e d , fo r s t a r t in g a s d e vice s t o lib e r a t e t h o u g h t , t h e y e n d o ft e n b y e n s la vin g it ’. Likewise, Calo notes that judges’ ‘selection of a metaphor or analogy for a new technology can determine legal outcomes’ surrounding AI. Lega l Dispositionism, pa rt 3(b) SMU Classification: Restricted Meanwhile… https://fortune.com/2023/07/18/elon-musk-xai-sam-altman-openai-artificial-superintelligence/ SMU Classification: Restricted In this Video… What is AI really? How “machine learning” works (but too briefly) How to think about AI systems in law

Use Quizgecko on...
Browser
Browser