Abstract. PiLib is a library written in Scala that implements the concurrency constructs of the π-calculus. Some features of the programming language Scala, examined in the paper, make it possible to use almost the same syntax as in the π-calculus. The advantages of this library with respect to a simple π-calculus interpreter are that we can transmit any value along names, we can get control over them using the type system, and we have access to the full power of Scala in terms of expressiveness and libraries.