#include <bits/stdc++.h>
using namespace std;
char s[2111111];
int pre[33];
long long dp[33];
int main() {
  int n, m, k;
  scanf("%d%d", &n, &k);
  scanf("%s", s);
  m = strlen(s);
  memset(pre, -1, sizeof pre);
  for (int i = 0; i < m; i++) {
    pre[s[i] - 'a'] = i;
  }
  for (int i = m; i < n + m; i++) {
    int pos = 2111111;
    char ch;
    for (int j = 0; j < k; j++) {
      if (pos > pre[j]) pos = pre[j], ch = 'a' + j;
    }
    s[i] = ch;
    pre[ch - 'a'] = i;
  }
  memset(dp, 0, sizeof dp);
  dp[s[0] - 'a'] = 1;
  for (int i = 1; i < n + m; i++) {
    dp[s[i] - 'a'] += 1;
    for (int j = 0; j < k; j++) {
      if (s[i] - 'a' == j) continue;
      dp[s[i] - 'a'] += dp[j];
      dp[s[i] - 'a'] %= 1000000007;
    }
  }
  long long ans = 0;
  for (int i = 0; i < k; i++) {
    ans += dp[i];
    ans %= 1000000007;
  }
  cout << (ans + 1) % 1000000007 << endl;
  return 0;
}
