Easy solution: Import it as a data table, and let the engine asset/file system support it.
Harder solution: When starting up, discover what the current working directory is, then look in that directory, and in each parent directory of that, for a folder named “Content” (or whatever your content folder name is.) Then use whatever path you discover as a prefix for the filename.
Add your text file to the “files to be included in packaging” setting in the project.
I forget what the exact name is – but there’s a way to include files/dependencies/packages that are local to your game, rather than the engine.
I recommend the easy solution. You have to learn how to use data tables once, but that will serve you well forever! And it’s a lot less hassle for built projects.