#include <bits/stdc++.h>
using namespace std;
int k, n, m, a[2000005], last[30];
char s[2000005];
const int mod = 1e9 + 7;
long long g[2000005], f[2000005];
inline int rd() {
  int x = 0, f = 1;
  char c = ' ';
  while (c < '0' || c > '9') {
    if (c == '-') f = -1;
    c = getchar();
  }
  while (c <= '9' && c >= '0') x = x * 10 + c - '0', c = getchar();
  return x * f;
}
int main() {
  m = rd();
  k = rd();
  scanf("%s", s + 1);
  n = strlen(s + 1);
  for (int i = 1; i <= n; i++) {
    a[i] = s[i] - 'a' + 1;
    if (last[a[i]] < 1)
      f[i] = (g[i - 1] + 1) % mod, g[i] = (f[i] + g[i - 1]) % mod;
    else
      f[i] = (g[i - 1] + mod - g[last[a[i]] - 1]) % mod,
      g[i] = (f[i] + g[i - 1]) % mod;
    last[a[i]] = i;
  }
  for (int i = n + 1; i <= n + m; i++) {
    int aim = 0, minn = 0x3f3f3f3f;
    for (int j = 1; j <= k; j++)
      if (minn > last[j]) aim = j, minn = last[j];
    a[i] = aim;
    if (last[aim] < 1)
      f[i] = (g[i - 1] + 1) % mod, g[i] = (f[i] + g[i - 1]) % mod;
    else
      f[i] = (g[i - 1] + mod - g[last[aim] - 1]) % mod,
      g[i] = (f[i] + g[i - 1]) % mod;
    last[aim] = i;
  }
  printf("%lld\n", (g[n + m] + 1) % mod);
  return 0;
}
