#include <bits/stdc++.h>
using namespace std;
const int MAXN = 3000000;
const int MAXM = 200000;
const int INF = 1000000010;
const long long int MOD = 1000000007;
const long long int P = 31;
const long double EPS = 1e-6;
int N, M, K;
char s[MAXN];
long long int dp[26] = {0};
int last_used[26];
int main() {
  ios_base::sync_with_stdio(false);
  scanf("%d %d", &M, &K);
  scanf("%s", s);
  N = strlen(s);
  memset(last_used, -1, sizeof(last_used));
  long long int tmp;
  for (int i = 0; i < N; i++) {
    tmp = 1;
    for (int j = 0; j < K; j++) {
      tmp = (tmp + dp[j]) % MOD;
    }
    dp[s[i] - 'a'] = tmp;
    last_used[s[i] - 'a'] = i;
  }
  int ptr;
  for (int i = 0; i < M; i++) {
    ptr = 0;
    tmp = 1;
    for (int j = 0; j < K; j++) {
      tmp = (tmp + dp[j]) % MOD;
      if (last_used[j] < last_used[ptr]) ptr = j;
    }
    dp[ptr] = tmp;
    last_used[ptr] = i + N;
  }
  tmp = 1;
  for (int i = 0; i < K; i++) tmp = (tmp + dp[i]) % MOD;
  printf("%I64d", tmp);
  return 0;
}
