Is it possible to use Agda as a library?
Instead of using Agda on a filesystem (with EMACS, terminal, etc.), is it possible to use it directly from Haskell, as a library? For example: -- UsingAgda.hs import Agda -- Prints the type of a term on some Agda code main :: IO () main = typeOf "true" agdaCode where agdaCode :: String agdaCode = unlines ["module Hello where " ," " ,"data Bool : Set where" ," true : Bool " ," false : Bool "] The code above would output Bool , because true : Bool on that Agda code. Yes, it is possible. Agda was designed as a Haskell library plus a main module. You can see a couple of small examples here . As a