It looks like you're tokenizing your text file by the pipe symbol, which is ASCII number 124. You weren't clear whether you want a random line, or you want a line that matches the nick. For a random line, something like this would work:

var %a $read(test.txt,nt) , %nick $gettok(%a,1,124) , %have $gettok(%a,2,124)
echo -a %nick you have %have

If you are using this in the ON TEXT event then $nick has the value of the person making the message. If it's inside the nicklist's rightclick menu, then the 1st highlighted nick is in $1. Assuming the value is in $nick, you can do something like:

var %a $read(test.txt,ntw,$nick $+ $chr(124) $+ *)
if (%a != $null) {
var %nick $gettok(%a,1,124) , %have $gettok(%a,2,124)
echo -a %nick you have %have
}

The nt switches aren't needed in this situation, but it's good to always use them, especially when the content is something that could have been created by not-you. The 't' switch prevents it from trying to look at line#1 as numeric. If 't' is not used, and line 1 is a number, then that number is used instead of the REAL total-number-of-lines in the text file when returning a random line. If the file has 100 lines and line #1 is not numeric, $read(file) returns a random line from lines 1-100. But if line#1 is changed to be the number 5, then it returns a random line from within the first 5 lines excluding line 1. If not using the 'n' switch, then it tries to evaluate the line, interpreting %word as if it's a variable or $word as if an identifier, and if the line contains the pipe symbol which doesn't have text touching it, it's treated as a separator between 2 commands