#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using pil = pair<int, ll>;
using pli = pair<ll, int>;
using piii = pair<int, pii>;
using plll = pair<ll, pll>;
using pib = pair<int, bool>;
using pdi = pair<double, int>;
using pid = pair<int, double>;
using ld = long double;
using piiii = pair<pii, pii>;
ll gcd(ll a, ll b) { return b == 0 ? a : gcd(b, a % b); }
ll lcm(ll a, ll b) { return a * b / gcd(a, b); }
ll fpow(ll b, ll exp, ll mod) {
  if (exp == 0) return 1;
  ll t = fpow(b, exp / 2, mod);
  if (exp & 1) return t * t % mod * b % mod;
  return t * t % mod;
}
ll divmod(ll i, ll j, ll mod) {
  i %= mod, j %= mod;
  return i * fpow(j, mod - 2, mod) % mod;
}
using namespace std;
const ll MOD = 1e9 + 7;
int n, m, k, vis = 0, ord[26];
ll dp[26];
string second;
int main() {
  ios::sync_with_stdio(0);
  cin >> n >> k >> second;
  m = second.length();
  memset(ord, -1, sizeof ord);
  for (int i = 0; i < m; i++) {
    ll t = 0;
    for (int j = 0; j < k; j++) {
      t = (t + dp[j]) % MOD;
    }
    dp[second[i] - 'a'] = (t + 1) % MOD;
    ord[second[i] - 'a'] = i;
  }
  for (int i = 0; i < n; i++) {
    int mn = 0;
    ll t = 0;
    for (int j = 0; j < k; j++) {
      if (ord[mn] > ord[j]) mn = j;
      t = (t + dp[j]) % MOD;
    }
    dp[mn] = (t + 1) % MOD;
    ord[mn] = i + m;
  }
  ll t = 1;
  for (int i = 0; i < k; i++) {
    t = (t + dp[i]) % MOD;
  }
  cout << t << "\n";
  return 0;
}
