import static java.util.Arrays.binarySearch;
import static java.util.Arrays.deepToString;
import static java.util.Arrays.sort;

import java.io.*;
import java.util.*;

public class lcm_nn_fast {
	static final int MOD = 1000000007;

	static void solve() throws Exception {
		long n = nextLong();
		int k = nextInt();
		out.println(solve(n, k));
	}

	static int solve(long n, int k) {
		Factor[] f = factorize(n);
		long[] d = getDivisors(n);
		int[] count = new int[d.length];
		count[0] = 1;
		for (int i = 1; i < d.length; i++) {
			long curD = d[i];
			for (int j = 0; j < f.length; j++) {
				if (curD % f[j].prime != 0) {
					continue;
				}
				long prime = f[j].prime;
				long curE = 1;
				int w = 1;
				while (curD % prime == 0) {
					curD /= prime;
					curE *= prime;
					w++;
				}
				if (curD == 1) {
					count[i] = w;
				} else {
					count[i] = count[binarySearch(d, curD)]
							* count[binarySearch(d, curE)];
				}
				break;
			}
		}
		int[][] dp = new int[k + 1][d.length];
		dp[0][0] = 1;
		for (int i = 0; i <= k; i++) {
			for (int j = 0; j < d.length; j++) {
				if (j < d.length - 1) {
					dp[i][j + 1] += dp[i][j];
					if (dp[i][j + 1] >= MOD) {
						dp[i][j + 1] -= MOD;
					}
				}
				if (i + 1 <= k) {
					dp[i + 1][j] += dp[i][j];
					if (dp[i + 1][j] >= MOD) {
						dp[i + 1][j] -= MOD;
					}
				}
			}
		}
		int[] function = dp[k];
		int ans = 0;
		for (int i = 0; i < 1 << f.length; i++) {
			long mul = 1;
			for (int j = 0; j < f.length; j++) {
				if (((i >> j) & 1) == 1) {
					mul *= f[j].prime;
				}
			}
			int curF = function[count[binarySearch(d, n / mul)] - 1];
			if (((Integer.bitCount(i)) & 1) == 0) {
				ans = ((ans + curF) % MOD);
			} else {
				ans = ((MOD + ans - curF) % MOD);
			}
		}
		return (ans);
	}

	static long[] getDivisors(long n) {
		List<Long> d = new ArrayList<Long>();
		for (long i = 1; i * i <= n; i++) {
			if (n % i != 0) {
				continue;
			}
			d.add(i);
			if (i * i != n) {
				d.add((n / i));
			}
		}
		long[] ret = new long[d.size()];
		for (int i = 0; i < d.size(); i++) {
			ret[i] = d.get(i);
		}
		sort(ret);
		return ret;
	}

	static Factor[] factorize(long n) {
		List<Factor> ret = new ArrayList<Factor>();
		for (long i = 2; i * i <= n; i++) {
			if (n % i != 0) {
				continue;
			}
			int count = 0;
			while (n % i == 0) {
				count++;
				n /= i;
			}
			ret.add(new Factor((int) i, count));
		}
		if (n > 1) {
			ret.add(new Factor(n, 1));
		}
		return ret.toArray(new Factor[ret.size()]);
	}

	static class Factor {
		long prime;
		int pow;

		public Factor(long prime, int pow) {
			this.prime = prime;
			this.pow = pow;
		}

	}

	static BufferedReader br;
	static StringTokenizer st;
	static PrintWriter out;

	static void debug(Object... a) {
		System.err.println(deepToString(a));
	}

	static int nextInt() throws IOException {
		return Integer.parseInt(next());
	}

	static String next() throws IOException {
		while (st == null || !st.hasMoreTokens()) {
			String line = br.readLine();
			if (line == null) {
				return null;
			}
			st = new StringTokenizer(line);
		}
		return st.nextToken();
	}

	static long nextLong() throws IOException {
		return Long.parseLong(next());
	}

	static double nextDouble() throws IOException {
		return Double.parseDouble(next());
	}

	public static void main(String[] args) {
		try {
			File file = new File("lcm.in");
			InputStream input = System.in;
			OutputStream output = System.out;
			if (file.canRead()) {
				input = (new FileInputStream(file));
				output = (new PrintStream("lcm.out"));
			}
			br = new BufferedReader(new InputStreamReader(input));
			out = new PrintWriter(output);
			solve();
			out.close();
			br.close();
		} catch (Throwable e) {
			e.printStackTrace();
			System.exit(1);
		}
	}
}