added keygen and mnemonic