#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  set<long long> zeros, ones;
  set<long long>::iterator it;
  for (long long int i = 0; i < int(s.size()); i++) {
    if ((s[i] - '0') == 0) {
      zeros.insert(i + 1);
    } else {
      ones.insert(i + 1);
    }
  }
  long long cur = 0, search = 0;
  vector<long long> tem;
  vector<vector<long long> > ans;
  bool f = true;
  while (1) {
    if (int(zeros.size()) == 0 && int(ones.size()) == 0) {
      break;
    }
    if (search == 0) {
      it = zeros.upper_bound(cur);
      if (it != zeros.end()) {
        tem.push_back(*it);
        cur = *it;
        zeros.erase(it);
        search = 1;
      } else {
        f = false;
        break;
      }
    } else if (search == 1) {
      it = ones.upper_bound(cur);
      if (it != ones.end()) {
        if (zeros.upper_bound(*it) != zeros.end()) {
          tem.push_back(*it);
          cur = *it;
          ones.erase(it);
          search = 0;
        } else {
          f = false;
          break;
        }
      } else {
        ans.push_back(tem);
        tem.clear();
        search = 0;
        cur = 0;
      }
    }
  }
  if (!f) {
    cout << -1 << '\n';
  } else {
    if (int(tem.size()) != 0) ans.push_back(tem);
    cout << int(ans.size()) << '\n';
    for (long long int i = 0; i < int(ans.size()); i++) {
      cout << int(ans[i].size()) << " ";
      for (long long int j = 0; j < int(ans[i].size()); j++) {
        cout << ans[i][j] << " ";
      }
      cout << '\n';
    }
  }
  return 0;
}
