You can make the code open source without accepting pull requests or contributions from other people. You might still get pull requests or patches, but you can set expectations up front and then ignore/auto-close any contributions you get.

This is how SQLite is developed, for example.