Skip to content

Instantly share code, notes, and snippets.

@yoavg
yoavg / LLMs.md
Last active February 17, 2024 18:39

Some remarks on Large Language Models

Yoav Goldberg, January 2023

Audience: I assume you heard of chatGPT, maybe played with it a little, and was imressed by it (or tried very hard not to be). And that you also heard that it is "a large language model". And maybe that it "solved natural language understanding". Here is a short personal perspective of my thoughts of this (and similar) models, and where we stand with respect to language understanding.

Intro

Around 2014-2017, right within the rise of neural-network based methods for NLP, I was giving a semi-academic-semi-popsci lecture, revolving around the story that achieving perfect language modeling is equivalent to being as intelligent as a human. Somewhere around the same time I was also asked in an academic panel "what would you do if you were given infinite compute and no need to worry about labour costs" to which I cockily responded "I would train a really huge language model, just to show that it doesn't solve everything!". We

{-# LANGUAGE DeriveFunctor, DeriveFoldable, DeriveTraversable, TypeFamilies, TemplateHaskell #-}
import Data.Functor.Foldable
import Data.Functor.Foldable.TH
import Data.Functor.Compose
-- Example type
data Exp
= IntValue Int
| Sum Exp Exp
@ChrisPenner
ChrisPenner / Optics Cheatsheet.md
Last active April 12, 2024 14:24
Optics Cheatsheet
@mstksg
mstksg / haskell.yml
Last active September 30, 2021 08:16
Stack Project Github Action Template
# Haskell stack project Github Actions template
# https://gist.github.com/mstksg/11f753d891cee5980326a8ea8c865233
#
# To use, mainly change the list in 'plans' and modify 'include' for
# any OS package manager deps.
#
# Currently not working for cabal-install >= 3
#
# Based on https://raw.githubusercontent.com/commercialhaskell/stack/stable/doc/travis-complex.yml
#
@chrisdone
chrisdone / README.md
Last active September 27, 2023 10:54
Indexed fields exploration

Exploring possibilities with simple indexed fields

Database records and formlets and optionally populated records can be neatly all represented with the same data type when the fields are all indexed.

class Indexed i a where
  type Index i (a :: *)
@i-am-tom
i-am-tom / Record.hs
Last active April 2, 2019 08:46
A tutorial in record manipulation.
{-# LANGUAGE AllowAmbiguousTypes #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE FunctionalDependencies #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TypeApplications #-}
{-# LANGUAGE TypeFamilies #-}
@gelisam
gelisam / Main.hs
Created December 12, 2018 04:21
Averaged across persons, excluding legal fees, how much money had each person spent by time 6?
-- in response to https://www.reddit.com/r/haskell/comments/a50xpr/datahaskell_solve_this_small_problem_to_fill_some/
{-# LANGUAGE BangPatterns, OverloadedStrings, RecordWildCards, ScopedTypeVariables #-}
module Main where
import Control.Category ((>>>))
import Data.Function ((&))
import Data.Map.Strict (Map, (!))
import Data.Set (Set)
import Test.DocTest (doctest)
@agocorona
agocorona / Transient.cont.hs
Last active April 26, 2023 08:00
Optimized, simplified continuation monad that implement all the Transient effects (except Web, logging and distributed computing) with mock up implementation of some of them (https://github.com/transient-haskell/transient) Parallelism, concurrency, reactive, streaming, non-determinism, backtracking exceptions, state, early termination
{-# LANGUAGE MultiParamTypeClasses, ExistentialQuantification, ScopedTypeVariables, FlexibleInstances, FlexibleContexts, UndecidableInstances #-}
module TransientCont where
-- some imports
import Control.Applicative
import Control.Monad.IO.Class
import Control.Monad.Trans
layout title date comments author categories commentIssueId
post
A comonad of graph decompositions
2016-04-02 13:02:54 -0400
true
Rúnar
scala comonads
22