#include <bits/stdc++.h>
using namespace std;
const int maxx = 1e6 + 7;
char s[maxx];
vector<vector<int>> ve;
int main() {
  cin >> s;
  int len = strlen(s);
  int l = 0, r = len - 1;
  while (1) {
    vector<int> temp;
    while (l < r) {
      while (s[l] != '(' && l < r) l++;
      while (s[r] != ')' && l < r) r--;
      if (l < r) temp.push_back(l), temp.push_back(r);
      l++, r--;
    }
    if (temp.size() == 0)
      break;
    else {
      sort(temp.begin(), temp.end());
      ve.push_back(temp);
    }
  }
  cout << ve.size() << endl;
  for (auto c : ve) {
    cout << c.size() << endl;
    for (auto cc : c) cout << cc + 1 << " ";
    cout << endl;
  }
}
