WordPress How To create Word document from theme and run it on new order created

require_once( '/word/vendor/autoload.php' ); will try to load starting from the root directory of your webserver. You’re probably looking for something like require_once( './word/vendor/autoload.php' ); or perhaps require_once( plugin_dir_path( __FILE__ ) . 'word/vendor/autoload.php' );.

(Note that plugin_dir_path() can be used in themes as well as plugins; the plugin part of its name is misleading.)